diff --git a/.deploy-infra/deploy-dev.yaml b/.deploy-infra/deploy-dev.yaml index 9e6ab90..998410a 100644 --- a/.deploy-infra/deploy-dev.yaml +++ b/.deploy-infra/deploy-dev.yaml @@ -138,10 +138,13 @@ services: order: start-first gitea-runner: - image: gitea/act_runner:nightly + image: mathwave/sprint-repo:gitea-runner volumes: - /var/run/docker.sock:/var/run/docker.sock - /sprint-data:/sprint-data + environment: + GITEA_INSTANCE_URL: gitea.sprinthub.ru + GITEA_RUNNER_REGISTRATION_TOKEN: $REGISTRATION_TOKEN deploy: mode: replicated placement: diff --git a/.deploy-infra/deploy-prod.yaml b/.deploy-infra/deploy-prod.yaml index 127a819..567e983 100644 --- a/.deploy-infra/deploy-prod.yaml +++ b/.deploy-infra/deploy-prod.yaml @@ -170,10 +170,13 @@ services: order: start-first gitea-runner: - image: gitea/act_runner:nightly + image: mathwave/sprint-repo:gitea-runner volumes: - /var/run/docker.sock:/var/run/docker.sock - /sprint-data:/sprint-data + environment: + GITEA_INSTANCE_URL: gitea.sprinthub.ru + GITEA_RUNNER_REGISTRATION_TOKEN: $REGISTRATION_TOKEN deploy: mode: replicated placement: diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6faa0f1..a1f2b3d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -28,6 +28,8 @@ build: - docker push mathwave/sprint-repo:sprint-infra-nginx-dev - docker build -t mathwave/sprint-repo:sprint-infra-nginx-prod nginx/nginx-prod - docker push mathwave/sprint-repo:sprint-infra-nginx-prod + - docker build -t mathwave/sprint-repo:gitea-runner gitea-runner + - docker push mathwave/sprint-repo:gitea-runner deploy-dev: stage: deploy-dev diff --git a/gitea-runner/Dockerfile b/gitea-runner/Dockerfile new file mode 100644 index 0000000..4e1e02d --- /dev/null +++ b/gitea-runner/Dockerfile @@ -0,0 +1,11 @@ +FROM gitea/act_runner:nightly + +RUN apt-get update +RUN apt-get install --yes ca-certificates curl gnupg lsb-release +RUN mkdir -p /etc/apt/keyrings +RUN curl -fsSL https://download.docker.com/linux/ubuntu/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg +RUN echo \ + "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \ + $(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null +RUN apt-get update --yes +RUN apt-get install --yes docker-ce docker-ce-cli containerd.io docker-compose-plugin