Hardware requirements

CPU
  • 1 core supports up to 100 users but the application can be a bit slower due to having all workers and background jobs running on the same core
  • 2 cores is the recommended number of cores and supports up to 500 users
  • 4 cores supports up to 2,000 users
  • 8 cores supports up to 5,000 users
  • 16 cores supports up to 10,000 users
  • 32 cores supports up to 20,000 users
  • 64 cores supports up to 40,000 users
  • More users? Run it on multiple application servers
Memory

You need at least 8GB of addressable memory (RAM + swap) to install and use GitLab! The operating system and any other running applications will also be using memory so keep in mind that you need at least 4GB available before running GitLab. With less memory GitLab will give strange errors during the reconfigure run and 500 errors during usage.

  • 4GB RAM + 4GB swap supports up to 100 users but it will be very slow
  • 8GB RAM is the recommended memory size for all installations and supports up to 100 users
  • 16GB RAM supports up to 2,000 users
  • 32GB RAM supports up to 4,000 users
  • 64GB RAM supports up to 8,000 users
  • 128GB RAM supports up to 16,000 users
  • 256GB RAM supports up to 32,000 users
  • More users? Run it on multiple application servers

Docker-compose

Below is a docker-compose.yml example with GitLab running on a custom HTTP and SSH port. Notice how the GITLAB_OMNIBUS_CONFIG variables match the ports section:

## 
#  gitlab-docker-compose.yml

version: '3.5'
services:
  gitlab-server:
    image: 'gitlab/gitlab-ce:latest'
    container_name: "ec.gitlab"
    restart: always
    hostname: 'd0o0bz.cn'
    environment:
      GITLAB_OMNIBUS_CONFIG: |
        external_url 'http://d0o0bz.cn:81'
        # gitlab_rails['gitlab_shell_ssh_port'] = 3222
    ports:
      - '81:81'
      - '3222:22'
    volumes:
      - '/home/e.c.com/gitlab/config:/etc/gitlab'
      - '/home/e.c.com/gitlab/logs:/var/log/gitlab'
      - '/home/e.c.com/gitlab/data:/var/opt/gitlab'
## 
#  启动
docker-compose -f gitlab-docker-compose.yml up -d

参考资料:
https://docs.gitlab.com/omnibus/docker/README.html