diff --git a/README.md b/README.md index ce0d696..d640c6e 100644 --- a/README.md +++ b/README.md @@ -281,23 +281,27 @@ Run `sudo gitlab-ctl reconfigure` for the LDAP settings to take effect. ### Enable HTTPS -By default, omnibus-gitlab does not use HTTPS. If you want to enable -HTTPS for gitlab.example.com, first place your key and certificate in +By default, omnibus-gitlab does not use HTTPS. If you want to enable HTTPS for +gitlab.example.com, add the following statement to `/etc/gitlab/gitlab.rb`: + +```ruby +external_url "https://gitlab.example.com" +``` + +Because the hostname in our example is 'gitlab.example.com', omnibus-gitlab +will look for key and certificate files called `/etc/gitlab/ssl/gitlab.example.com.key` and -`/etc/gitlab/ssl/gitlab.example.com.crt`, respectively. +`/etc/gitlab/ssl/gitlab.example.com.crt`, respectively. Create the +`/etc/gitlab/ssl` directory and copy your key and certificate there. ``` sudo mkdir -p /etc/gitlab/ssl sudo chmod 700 /etc/gitlab/ssl -sudo cp gitlab.example.com.crt gitlab.example.com.key /etc/gitlab/ssl/ +sudo cp gitlab.example.com.key gitlab.example.com.crt /etc/gitlab/ssl/ ``` -Next, add the following line to `/etc/gitlab/gitlab.rb` and run `sudo -gitlab-ctl reconfigure`. - -```ruby -external_url "https://gitlab.example.com" -``` +Now run `sudo gitlab-ctl reconfigure`. When the reconfigure finishes your +GitLab instance should be reachable at `http://gitlab.example.com`. If you are using a firewall you may have to open port 443 to allow inbound HTTPS traffic. -- libgit2 0.21.2