De novo um erro semelhante ao anterior, mas diferente. Só mexi no estagio de teste e o erro aparece no estagio inicial, não entendo pq. Repeti a execução e nao resolve. Tentei ver no forum a solução, mexer no arquivo config.toml, mas nao sei por onde se faz isso.
Executing "step_script" stage of the job script
00:04
$ docker info
Client:
Debug Mode: false
Server:
ERROR: error during connect: Get http://docker:2375/v1.40/info: dial tcp: lookup docker on 10.0.2.3:53: no such host
meu yml
image: docker:19.03.0
stages:
- pre-build
- build
- test
- deploy
build-docker:
services:
- docker:19.03.0-dind
variables:
DOCKER_HOST: tcp://docker:2375
DOCKER_DRIVER: overlay2
DOCKER_TLS_CERTDIR: ""
GIT_SSL_NO_VERIFY: "1"
before_script:
- docker info
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD
stage: pre-build
script:
- docker build -t todo-list-img .
- docker tag todo-list-img azosnosredna/gitlab_todolist_img:latest
- docker push azosnosredna/gitlab_todolist_img:latest
build-project:
image: azosnosredna/gitlab_todolist_img:latest
services:
- docker:19.03.0-dind
- mysql:5.7
variables:
MYSQL_USER: devops_dev
MYSQL_PASSWORD: mestre
MYSQL_DATABASE: todo_dev
MYSQL_ROOT_PASSWORD: senha
DB_NAME: 'todo_dev'
DB_USER: 'devops_dev'
DB_PASSWORD: 'mestre'
DB_HOST: 'mysql'
DB_PORT: '3306'
SECRET_KEY: 'r*5ltfzw-61ksdm41fuul8+hxs$86yo9%k1%k=(!@=-wv4qtyv'
stage: build
image: azosnosredna/gitlab_todolist_img:latest
tags:
- executor-tarefas
dependencies:
- build-docker
script:
- python manage.py makemigrations
- python manage.py migrate
test-project:
image: azosnosredna/gitlab_todolist_img:latest
stage: test
services:
- docker:19.03.0-dind
- mysql:5.7
variables:
MYSQL_USER: devops_dev
MYSQL_PASSWORD: mestre
MYSQL_DATABASE: todo_dev
MYSQL_ROOT_PASSWORD: senha
DB_NAME: 'todo_dev'
DB_USER: 'devops_dev'
DB_PASSWORD: 'mestre'
DB_HOST: 'mysql'
DB_PORT: '3306'
SECRET_KEY: 'r*5ltfzw-61ksdm41fuul8+hxs$86yo9%k1%k=(!@=-wv4qtyv'
dependencies:
- build-project
tags:
- executor-tarefas
script:
- python -m unittest setUp