CentOS 7.x gitlab on lxc container

From Notes_Wiki

Home > CentOS > CentOS 7.x > DevOps > Version Control > gitlab > CentOS 7.x gitlab on lxc container

To install gitlab on lxc-container use following steps:

  1. Install required packages
    yum install -y curl policycoreutils-python sudo
  2. If firewalld is installed then either disable Firewalld or allow ports 22,80,443 via firewalld
  3. Optionally install and configure postfix
  4. Setup repository using:
    curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ee/script.rpm.sh | sudo bash
  5. Optionally configure yum with keepcache=1 as gitlab setup is about 600MB
  6. Install gitlab using:
    yum install -y gitlab-ee
    OR if server is publically accessible over FQDN
    sudo EXTERNAL_URL="https://gitlab.example.com" yum install -y gitlab-ee
    Note that gitlab-ee can be installed by anyone. Without license it would work like gitlab-ce
  7. Edit /etc/gitlab/gitlab.re and update external_url
  8. Run 'sudo gitlab-ctl reconfigure' which shows below error
    Running handlers:
    There was an error running gitlab-ctl reconfigure:
    service[grafana] (dynamically defined) had an error: Mixlib::ShellOut::ShellCommandFailed: Expected process to exit with [0], but received '1'
    ---- Begin output of /opt/gitlab/embedded/bin/chpst -u root:root /opt/gitlab/embedded/bin/sv restart /opt/gitlab/service/grafana ----
    STDOUT: timeout: run: /opt/gitlab/service/grafana: (pid 2309) 48s, got TERM
    STDERR:
    ---- End output of /opt/gitlab/embedded/bin/chpst -u root:root /opt/gitlab/embedded/bin/sv restart /opt/gitlab/service/grafana ----
    Ran /opt/gitlab/embedded/bin/chpst -u root:root /opt/gitlab/embedded/bin/sv restart /opt/gitlab/service/grafana returned 1
    Running handlers complete
    Chef Client failed. 524 resources updated in 06 minutes 25 seconds
  9. Start gitlab despite errors using:
    gitlab-ctl start
  10. Then access at http://<fqdn> and set required password for root user. Then login with username root


Refer:



Home > CentOS > CentOS 7.x > DevOps > Version Control > gitlab > CentOS 7.x gitlab on lxc container