Date: Thu, 28 Mar 2024 12:29:51 +0000 (UTC) Message-ID: <564914754.155.1711628991686@confluence.devops.pub.tds.tieto.com> Subject: Exported From Confluence MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_Part_154_471819317.1711628991685" ------=_Part_154_471819317.1711628991685 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Location: file:///C:/exported.html
GitLab Runner is an application that works w= ith GitLab CI/CD to run jobs in a pipeline.
This section describes how to install and configure GitLab runner using = docker on some server.
Deploy virtual server in Portal
Skip this step if you already have a server.
If you need new server, you can deploy one via TDS portal - Orchestration - Servers#Howtodeploy= newserver
Option A - using "convenience script" f= rom official = instructions =E2=80=93 recommended only for development and testing pur= poses
curl -f= sSL https://get.docker.com -o get-docker.sh sudo sh get-docker.sh sudo systemctl start docker
CentOS - offic= ial instructions
sudo yu= m install -y yum-utils sudo yum-config-manager --add-repo https://download.docker.com/linux/centos= /docker-ce.repo sudo yum install docker-ce docker-ce-cli containerd.io docker-buildx-plugin= docker-compose-plugin -y
Fedora - offic= ial instructions
sudo dn= f -y install dnf-plugins-core sudo dnf config-manager --add-repo https://download.docker.com/linux/fedora= /docker-ce.repo sudo dnf install docker-ce docker-ce-cli containerd.io docker-buildx-plugin= docker-compose-plugin -y
Ubuntu - official instructions
sudo ap= t-get update sudo apt-get install ca-certificates curl gnupg lsb-release -y sudo mkdir -m 0755 -p /etc/apt/keyrings curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmo= r -o /etc/apt/keyrings/docker.gpg echo "deb [arch=3D$(dpkg --print-architecture) signed-by=3D/etc/apt/keyring= s/docker.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) s= table" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
Add your user to docker group to be abl= e to run docker commands (more about security in article)
sudo us= ermod -aG docker $USER
Start docker container with latest vers= ion of gitlab runner (official instructions)
docker = run -d --name gitlab-runner --restart always -v /srv/gitlab-runner/config:/= etc/gitlab-runner -v /var/run/docker.sock:/var/run/docker.sock gitlab/gitla= b-runner:latest
Execute following command on the server= with running docker container
docker = exec -it gitlab-runner gitlab-runner register --docker-privileged