{"id":18023379,"url":"https://github.com/beginor/docker-gitlab-ce","last_synced_at":"2025-06-17T18:33:52.555Z","repository":{"id":144769249,"uuid":"58865638","full_name":"beginor/docker-gitlab-ce","owner":"beginor","description":"GitLab CE zh-cn docker file","archived":false,"fork":false,"pushed_at":"2018-12-27T03:01:16.000Z","size":38,"stargazers_count":67,"open_issues_count":1,"forks_count":19,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-04-04T18:19:28.934Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/beginor.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-05-15T14:20:28.000Z","updated_at":"2023-09-07T01:40:19.000Z","dependencies_parsed_at":"2024-06-14T11:03:51.378Z","dependency_job_id":null,"html_url":"https://github.com/beginor/docker-gitlab-ce","commit_stats":null,"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/beginor/docker-gitlab-ce","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beginor%2Fdocker-gitlab-ce","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beginor%2Fdocker-gitlab-ce/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beginor%2Fdocker-gitlab-ce/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beginor%2Fdocker-gitlab-ce/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/beginor","download_url":"https://codeload.github.com/beginor/docker-gitlab-ce/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beginor%2Fdocker-gitlab-ce/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260419031,"owners_count":23006197,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-30T07:09:14.067Z","updated_at":"2025-06-17T18:33:47.544Z","avatar_url":"https://github.com/beginor.png","language":"Dockerfile","funding_links":[],"categories":["Dockerfile"],"sub_categories":[],"readme":"# 重要声明\n\ngitlab 官方已经开始支持多语言， 而且也提供了 docker 镜像， 因此这个 docker 镜像不再维护， 请大家切换到官方镜像， 感谢大家的支持。\n\n\u003e 切换到官方镜像之后， 中文设置方法： 依次点击工具栏最右侧用户头像 》 `Settings` 》 `Preferred language` ， 然后选择 `简体中文` 即可。\n\n# GitLab 中文社区版 Docker 镜像\n\n基于 GitLab 官方社区版 Docker 镜像制作的中文 Docker 镜像， 汉化补丁来自网友 [larryli](https://gitlab.com/larryli/gitlab) (8.8.5之前)， 后续由网友 [xhang](https://gitlab.com/xhang/gitlab) 维护。\n\n由于汉化工作需要大量的人力， 所以中文版的版本会比官方的版本稍低， 如果刻意最求最新版， 请使用官方的 GitLab Docker 镜像。\n\n如果发现汉化的问题， 请向 [xhang](https://gitlab.com/xhang/gitlab) 反映。\n\n## 获取镜像\n\n```sh\ndocker pull beginor/gitlab-ce:11.3.0-ce.0\n```\n\n## 运行\n\n通常会将 GitLab 的配置 (etc) 、 日志 (log) 、数据 (data) 放到容器之外， 便于日后升级， 因此请先准备这三个目录。\n\n```sh\nsudo mkdir -p /mnt/sda1/gitlab/etc\nsudo mkdir -p /mnt/sda1/gitlab/log\nsudo mkdir -p /mnt/sda1/gitlab/data\n```\n准备好这三个目录之后， 就可以开始运行 Docker 镜像了。 我的建议是使用`unless-stopped` 作为重启策略， 因为这样可以手工停止容器， 方便维护。\n\n完整的运行命令如下：\n\n```sh\ndocker run \\\n    --detach \\\n    --publish 8443:443 \\\n    --publish 8080:80 \\\n    --name gitlab \\\n    --restart unless-stopped \\\n    --volume /mnt/sda1/gitlab/etc:/etc/gitlab \\\n    --volume /mnt/sda1/gitlab/log:/var/log/gitlab \\\n    --volume /mnt/sda1/gitlab/data:/var/opt/gitlab \\\n    beginor/gitlab-ce:11.3.0-ce.0\n```\n\n## 升级\n\n小版本升级（例如从 8.8.2 升级到 8.8.3）， 参照官方的说明， 将原来的容器停止， 然后删除：\n\n```sh\ndocker stop gitlab\ndocker rm gitlab\n```\n\n然后重新拉一个新版本的镜像下来， \n\n```sh\ndocker pull beginor/gitlab-ce:11.3.0-ce.0\n```\n\n还使用原来的运行命令运行， \n\n```sh\ndocker run \\\n    --detach \\\n    --publish 8443:443 \\\n    --publish 8080:80 \\\n    --name gitlab \\\n    --restart unless-stopped \\\n    --volume /mnt/sda1/gitlab/etc:/etc/gitlab \\\n    --volume /mnt/sda1/gitlab/log:/var/log/gitlab \\\n    --volume /mnt/sda1/gitlab/data:/var/opt/gitlab \\\n    beginor/gitlab-ce:11.3.0-ce.0\n```\n\nGitLab 在初次运行的时候会自动升级， 为了预防万一， 还是建议先备份一下 `/mnt/sda1/gitlab/` 这个目录。\n\n大版本升级（例如从 8.7.x 升级到 8.8.x）用上面的操作有可能会出现错误， 如果出现错误可以尝试登录到容器内部， 可以用 `docker exec` ， 也可以用 ssh ， 依次执行下面的命令：\n\n```sh\ngitlab-ctl reconfigure\ngitlab-ctl restart\n```\n\n## 更多\n\n想知道更多高级的玩法， 请参考这些： \n\n- The official GitLab Community Edition Docker image is [available on Docker Hub](https://registry.hub.docker.com/u/gitlab/gitlab-ce/).\n- The official GitLab Enterprise Edition Docker image is [available on Docker Hub](https://registry.hub.docker.com/u/gitlab/gitlab-ee/).\n- The complete usage guide can be found in [Using GitLab Docker images](http://doc.gitlab.com/omnibus/docker/).\n- The Dockerfile used for building public images is in [Omnibus Repository](https://gitlab.com/gitlab-org/omnibus-gitlab/tree/master/docker).\n- Check the guide for [creating Omnibus-based Docker Image](http://doc.gitlab.com/omnibus/build/README.html#Build-Docker-image).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbeginor%2Fdocker-gitlab-ce","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbeginor%2Fdocker-gitlab-ce","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbeginor%2Fdocker-gitlab-ce/lists"}