I have 2 EC2s, one with Gitlab-ee installed, another with Docker installed and running Gitlab-Runner and a Registry container.
Gitlab-Runner is working, and picks up the commit to Gitlab, shipping it to docker for it's build phase. However during the build phase when the docker container attempts to login to the Registry container it errors with "http: server gave HTTP response to HTTPS client"
Docker Login code:
docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
Troubleshooting done:
- If I ssh into the server, I can login with
sudo docker login localhost:5000 - The same error occurs if the registry is referenced with $CI_REGISTRY / localhost / DNS name
- I ensured the CI_REGISTRY is set in gitlab.rb
- I saw some mentions online about needing to use the --insecure-registries flag in the docker.service Exec line, and I did that as well and get the same error.
- This works if the docker installation is on the same server, but I'm trying to decouple the two applications from each other so they can be managed separately.
Software verions:
- Docker Version: 19.03.6
- Gitlab-ee Version: 12.8.1
- Gitlab-Runner Version: 12.8.0
If anyone could help me on this, it would be greatly appreciated! I've been banging my head against it for 2 days.