Skip to content

How do I download a private repository? #339

Discussion options

You must be logged in to vote

This worked for me on a docker host:
(example uses gitlab, should adapt to other registries, too)

  1. Obtain deploy user credentials. On a gitlab project, navigate to settings -> repository -> deploy token and create a token with permission to read registry
  2. SSH to your host, authenticate as root
  3. use docker login registry.gitlab.com -u USER -p PASSWORD to authenticate with the created credentials
  4. This is important, if you work with different repositories using different deployment credentials:
    1. open /root/.docker/config.json for editing
    2. Find the entry for registry.gitlab.com and append the path of your image, should look like this: registry.gitlab.com/cyberbellum96/this-my-repo
    3. Now this crede…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by cyberbellum96
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 participants