Skip to content

Instantly share code, notes, and snippets.

@GiantRobato
Last active February 6, 2020 02:09
Show Gist options
  • Save GiantRobato/78b08f86bd16bfc9497848e169d82ffb to your computer and use it in GitHub Desktop.
Save GiantRobato/78b08f86bd16bfc9497848e169d82ffb to your computer and use it in GitHub Desktop.
Self Serve SSL gitlab

Instructions

After you create your cert + cert key, enable by updating nginx

sudo gitlab-ctl hup nginx

Old instructions

# in /etc/gitlab/gitlab.rb
nginx['ssl_certificate'] = "/etc/gitlab/ssl/#{node['fqdn']}.crt"
nginx['ssl_certificate_key'] = "/etc/gitlab/ssl/#{node['fqdn']}.key"

then reconfigure gitlab:

sudo gitlab-ctl reconfigure

allow portforwarding

# UFW example (Debian, Ubuntu)
sudo ufw allow https

# lokkit example (RedHat, CentOS 6)
sudo lokkit -s https

# firewall-cmd (RedHat, Centos 7)
sudo firewall-cmd --permanent --add-service=https
sudo systemctl reload firewalld
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment