How to Downlaod and Install GitLab Latest Version in Ubuntu 24.04 LTS?
May 9, 2024 2024-05-11 13:23How to Downlaod and Install GitLab Latest Version in Ubuntu 24.04 LTS?
To download and install GitLab on Ubuntu 24.04 LTS, you can follow these steps:
Update Your Package Lists: Before installing any new software, it’s always a good practice to update your package lists to ensure you’re getting the latest versions of the software.
sudo apt-get update
Install Dependencies: GitLab has a few dependencies that need to be installed before you can proceed. Install them by running the following command:
sudo apt-get install -y curl openssh-server ca-certificates tzdata perl
Install necessary Packages: By installing these packages, you’re adding essential functionality to your Ubuntu system. Postfix will handle email services, Vim will provide a powerful text editor, and net-tools will provide network-related command-line tools for network configuration and troubleshooting.
sudo apt-get install -y postfix vim net-tools
Add GitLab Package Repository: GitLab provides official repositories for Ubuntu. Add the GitLab package repository to your system by running the following command:
sudo sed -i "s/noble/jammy/g" /etc/apt/sources.list.d/gitlab_gitlab-*e.list
Install GitLab Package: After adding the repository, you can now install GitLab.
apt-get update
sudo EXTERNAL_URL="https://repos.cloudishsoft.com"
sudo apt-get install gitlab-ce
Replace https://repos.cloudishsoft.com with your actual domain name or IP address. This is the URL through which you will access your GitLab instance.
Configure GitLab: Once the installation is complete, you’ll need to configure GitLab. By default, the configuration file is located at /etc/gitlab/gitlab.rb. You may need to edit this file to customize GitLab according to your needs. For example, you can configure the external URL, SMTP settings, and other options.
Reconfigure GitLab: After making changes to the configuration file, you need to run the following command to apply the changes:
sudo gitlab-ctl reconfigure
Get the status: Running gitlab-ctl status will display the status of all the GitLab services, indicating whether they are running or not.
sudo gitlab-ctl status
run: alertmanager: (pid 2160) 47513s; run: log: (pid 2141) 47513s
run: gitaly: (pid 2162) 47513s; run: log: (pid 2142) 47513s
run: gitlab-exporter: (pid 2158) 47513s; run: log: (pid 2123) 47513s
run: gitlab-kas: (pid 2161) 47513s; run: log: (pid 2146) 47513s
run: gitlab-workhorse: (pid 2159) 48592s; run: log: (pid 2145) 47513s
run: logrotate: (pid 21524) 37791s; run: log: (pid 2251) 47513s
run: nginx: (pid 2163) 47513s; run: log: (pid 2150) 47513s
run: node-exporter: (pid 2167) 47513s; run: log: (pid 2253) 47513s
run: postgres-exporter: (pid 2156) 47513s; run: log: (pid 2242) 47513s
run: postgresql: (pid 2169) 47513s; run: log: (pid 2249) 47513s
run: prometheus: (pid 2157) 47513s; run: log: (pid 2241) 47513s
run: puma: (pid 2166) 47513s; run: log: (pid 2254) 47513s
run: redis: (pid 2165) 47513s; run: log: (pid 2252) 47513s
run: redis-exporter: (pid 2155) 47513s; run: log: (pid 2240) 47513s
run: sidekiq: (pid 2164) 47513s; run: log: (pid 2248) 47513s
or you can check the status by the following command also,
$ service gitlab-runsvdir status