Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the special gitlab-ci-token user?

The docs for gitlab's container registry (https://gitlab.com/help/container_registry/README.md) provide a config example with this instruction:

- docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN registry.example.com

and this explanation:

You have to use the credentials of the special gitlab-ci-token user with its password stored in $CI_BUILD_TOKEN in order to push to the Registry connected to your project. This allows you to automated building and deployment of your Docker images.

I cannot find any documentation about this special gitlab-ci-token user, nor about the $CI_BUILD_TOKEN var.

What is this special user? Is it automatically available? Does it have to be defined somewhere? What value should be given to the $CI_BUILD_TOKEN var?

like image 440
user1447137 Avatar asked May 26 '16 18:05

user1447137


1 Answers

Gitlab acts as an authentication provider for the registry. gitlab-ci-token is a user automatically created for you. CI_BUILD_TOKEN is set automatically for each build by Gitlab-CI

like image 80
Martin Avatar answered Sep 22 '22 06:09

Martin