Gitlab registry

Hi,

Can I use Gitlab’s internal container registry to push docker containers to and can I also make it available from the outside?
I am running my own Gitlab v14.6 instance and I have installed it on a debian 11 server, by installing the native packages on the system. I can reach the gitlab server on https://gitlab.mycompany.com and also the registry is available on https://registry.gitlab.mycompany.com.
In the admin area I can see the container registry is online and running.
I have tried to configure external access to the container registry, by following the documentation: https://docs.gitlab.com/ee/administration/packages/container_registry.html, but it is quite unclear on what I should configure. Do I need to edit the file /etc/gitlab/gitlab.rb and then run the command gitlab-ctl reconfigure, or do I need to edit the individual yaml files?
Or is it best to disable this internal registry al together and run a separate docker registry container?

Thank you in advance. If I need to provide additional information, then please let me know.

Kind regards,

Pascal Herms

Hello,

How have you tried accessing it so far? Push? Pull?

In your own instance, maybe follow these steps if you have not yet:

  • Create a group
  • In the group administration create an deployment token with Read & Write access to registry.
  • Login to the registry with the token credentials (this can already be considered a success)
  • Push an image to the registry
  • Pull an image from the registry

Your idea of using the registry for pushing and pulling docker containers is exactly right.

If you need more help let us know. All the best!

Hi,

So far I have only tried to push an image to the registry.

I have also created a group and created a deployment token and setup read and write access to the registry.
I think in itself the registry is working, but I am having trouble figuring/checking what settings to configure so that the registry available on registry.gitlab.mycompany.com.
In the documentation there are 2 methods mentioned. One is to edit the /etc/gitlab/gitlab.rb file and the other is to edit the yaml file(s) in the /opt/gitlab/gitlab-rails (not sure about the exact path here). I have files on both locations which I can edit.
I guess what I am looking for is: do this, then this, then this, configure your firewall and Bob’s your uncle.

Kind regards,
P. Herms