googlegitlab

Modify the GitLab host name

Change the default address automatically

It is advisable to use a host name instead of an IP address for Gitlab. However, we recommend not using git. in the host name as this causes problems when accessing Gitlab over HTTP.

Follow these steps:

  • At the server console, run the following command:

      $ sudo /opt/bitnami/configure_app_domain --domain IP_OR_DOMAIN
    

    NOTE: If the result of the previous command shows a command not found error, execute the following command instead:

    $ sudo /opt/bitnami/apps/gitlab/bnconfig --machine_hostname IP_OR_DOMAIN
    

    IMPORTANT: If you’ve configured GitLab to use a static domain name, remove or rename the /opt/bitnami/apps/gitlab/bnconfig file to avoid it being reset on the next system reboot.

Change the default address manually for GitLab

To configure an external URL for GitLab, modify the external_url parameter in the /etc/gitlab/gitlab.rb file:

external_url "https://gitlab.example.com"
  • Run the gitlab-ctl script to apply the changes as follows:

      $ sudo gitlab-ctl reconfigure
    
Last modification December 21, 2022