DispelEvilBot/deploy/runner/docker-compose.yml

26 lines
1.2 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Act runner для Forgejo/Gitea Actions (регистрация по токену).
# Подходит для Forgejo 1.21, где на странице Runners показывается Registration Token.
#
# 1) Forgejo -> Site Administration -> Actions -> Runners
# Скопировать Registration Token (там же кнопка копирования).
# 2) cp .env.example .env и вписать RUNNER_TOKEN (FORGEJO_URL по умолчанию верный).
# 3) docker compose up -d и проверить: docker compose logs -f runner
#
# Раннер запускает джобы в контейнерах и использует docker.sock,
# поэтому для сборки образов внутри CI нужен образ с docker CLI.
services:
runner:
image: gitea/act_runner:latest
restart: unless-stopped
environment:
GITEA_INSTANCE_URL: ${FORGEJO_URL:-https://git.mpakosrv.ru}
GITEA_RUNNER_REGISTRATION_TOKEN: ${RUNNER_TOKEN:?задайте RUNNER_TOKEN в .env}
GITEA_RUNNER_NAME: ${RUNNER_NAME:-home-runner}
GITEA_RUNNER_LABELS: ubuntu-latest:docker://catthehacker/ubuntu:act-latest
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- runner_data:/data
volumes:
runner_data: