sameersbn / sameersbn/docker-gitlab

Store repositories on external volume

Open
#1,317 7 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

wontfix
Dominant language
Shell
Stars
8.1k
Forks
2.1k
Avg merge
17h 47m
Merged PRs (30d)
7

Description

Hello together,

I would like to store the content of my gitlab externally. However, the repositories are not stored within the docker container nor in the external path. I cannot find them anywhere. But new projects can be created.

I create the container like this:

docker run \
--name gitlab2_app \
--hostname xxx\
--link gitlabN-postgresql:postgresql \
--link gitlabN-redis:redisio \
--publish 2289:22 \
--publish 8929:80 \
--userns=host \
--privileged \
--restart=always \
-e 'GITLAB_REPOS_DIR=/home/xxx/external_storage/docker/volumes/diva_gitlab/data/repositories' \
-e 'GITLAB_BUILDS_DIR=/home/xxx/external_storage/docker/volumes/diva_gitlab/data/builds' \
-e 'GITLAB_BACKUP_DIR=/home/xxx/external_storage/docker/volumes/diva_gitlab/data/backups' \
-e 'GITLAB_DOWNLOADS_DIR=/home/xxx/external_storage/docker/volumes/diva_gitlab/data/downloads' \
-e 'GITLAB_SHARED_DIR=/home/xxx/external_storage/docker/volumes/diva_gitlab/data/shared' \
-e 'GITLAB_ARTIFACTS_DIR=/home/xxx/external_storage/docker/volumes/diva_gitlab/data/artifacts' \
--volume /home/xxx/external_storage/docker/volumes/diva_gitlab/data:/home/git/data \
--volume /home/xxx/external_storage/docker/volumes/diva_gitlab/log:/var/log/gitlab \
sameersbn/gitlab:latest

  1. What do I have to change that my gitlab starts using the external directory?
  2. From another gitlab installation I have some user folders in a repository directory, that I would like to move to my new installation. However, that old gitlab installation is not working anymore and I would like to transfer these repositories to the new installation. Is that possible?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names no repository file, test, or entry point. Start by checking how the sameersbn/gitlab image handles GITLAB_REPOS_DIR and the /home/git/data volume mapping, then verify where newly created repositories are written. Done means resolving the external-volume configuration and determining whether the existing repository folders can be transferred.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, gitlab, shell
Domain
devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.