Install GitLab


curl -fsSL | gpg --dearmor > /usr/share/keyrings/gitlab_gitlab-ce-archive-keyring.gpg
deb [signed-by=/usr/share/keyrings/gitlab_gitlab-ce-archive-keyring.gpg] $(lsb_release -cs) main
deb-src [signed-by=/usr/share/keyrings/gitlab_gitlab-ce-archive-keyring.gpg] $(lsb_release -cs) main

Old install


# ensure that this script is run by root
if [ $(id -u) -ne 0 ]; then
    sudo $0

# install required packages
apt-get install -y ca-certificates curl cron

#  bypass the apt-cacher-ng proxy
echo ' "DIRECT";' > /etc/apt/apt.conf.d/99_gitlab

# download GitLab installation script
curl -s | bash

# workaround for PostgreSQL shmmax issue
echo "kernel.shmmax=17179869184" >> /etc/sysctl.d/90-shmmax.conf
/sbin/sysctl -p /etc/sysctl.d/90-shmmax.conf

# install GitLab Community Edition
apt-get install -y gitlab-ce

# configure domain
sed -i "s||$(hostname -A | tr -d ' ')|g" /etc/gitlab/gitlab.rb
gitlab-ctl reconfigure



user: root
pass: 5iveL!fe

Downloads: GitLab CE Download Archives

# check instalation
gitlab-rake gitlab:check

# GitLab APT repository

# rebuild an authorized_keys file
gitlab-rake gitlab:shell:setup
# install specific version
sudo apt-get install -y gitlab-ce=7.10.1~omnibus.1-1

Send email notification
Notify.test_email('', 'GitLab test subject', 'GitLab test message').deliver_now

GitLab backup to s3

# /etc/gitlab/gitlab.rb
gitlab_rails['backup_upload_connection'] = {
  'provider' => 'AWS',
  'region' => 'ew-west-1',
  'aws_access_key_id' => 'foo,
  'aws_secret_access_key' => 'bar',
  'endpoint' => ''
gitlab_rails['backup_upload_remote_directory'] = 'backups'

Skip DB migration

gitlab_rails['auto_migrate'] = false
sudo gitlab-ctl reconfigure
apt install gitlab-ce=14.9.4-ce.0
apt-cache madison  gitlab-ce | grep 14.10

Links - old GitLab packages archive