前言
略
docker-compose方式部署
cat > docker-compose.yml <<-EOF
version: "3.6"
services:
gitlab:
image: gitlab/gitlab-ce:latest
container_name: gitlab
restart: always
hostname: gitlab.cjkj.co
ports:
- 80:80
- 443:443
- 9922:22
volumes:
- /opt/gitlab/config:/etc/gitlab:Z # 用于存储GitLab配置文件
- /opt/gitlab/logs:/var/log/gitlab:Z # 用于存储日志
- /opt/gitlab/data:/var/opt/gitlab:Z # 用于存储应用程序数据
EOF