We are facing issue with storing gitlab registry credentials in Drone UI. Below is the docker compose file.
Please help in this issue.
@sravan1265 there are no known issues with saving registry credentials, so we would need more details to further advise (example: server logs, error message in browser console, etc). Also is this related to this existing thread: Unable to push docker images to GitLab private registry throwing Denied: access forbidden ?
Also please note the difference between registry credentials and secrets. Registry credentials are only used to pull private images defined in the
image: attribute in your yaml. For example, we would use registry credentials to pull the below image:
+ image: registry.company.com/some-image
However, if you need to reference these credentials inside your pipeline (e.g. in your script) you need to use secrets:
- docker build
- docker login -u $REGISTRY_USERNAME -p $REGISTRY_PASSWORD https://gitlab.xxxxxxxx.com/
- docker push ....
+ secrets: [ REGISTRY_USERNAME, REGISTRY_PASSWORD ]
Thanks for the quick response, I understood with the storing registry crendentials in the Drone UI and i am clear with the difference between registry credentials and secrets.
I have fixed the issue for now.
My main issue is with “Unable to push docker images to GitLab private registry throwing Denied: access forbidden”.
can you please help me in this issue.
Hi @sravan1265, triaging issues with the
docker login and
docker push commands are outside the scope of support I provide in this forum, since they do not appear to be directly related to the underlying Drone software. If you are having difficulty with these commands, or the GitLab registry, you might be better serviced by engaging GitLab or Docker support.