chore: committing missing files from previous logic changes

This commit is contained in:
2026-07-10 21:55:37 +01:00
parent 1ae71cbae3
commit 547fee06fa
6 changed files with 80 additions and 33 deletions
+12 -17
View File
@@ -1,31 +1,26 @@
# Generated by OpenTofu from var.dev_runner_count - do not hand-edit.
# To change the number of runners, edit dev_runner_count in terraform.tfvars and
# run tofu apply. To change their shape, edit
# infra/modules/dev/templates/runners-docker-compose.yml.tftpl instead.
#
# GITEA_RUNNER_REGISTRATION_TOKEN is intentionally left as a compose variable
# (not baked in here) - services/dev/spinup.sh generates a fresh token and
# writes it to Runners/.env immediately before starting these containers.
services:
# Runner
runner:
runner-1:
image: gitea/act_runner:latest
container_name: gitea_runner
container_name: gitea_runner_1
volumes:
- ./config.yaml:/config.yaml
- ./gitea_runner:/data
- ./gitea_runner_1:/data
- /var/run/docker.sock:/var/run/docker.sock
networks:
- proxy
environment:
CONFIG_FILE: /config.yaml
GITEA_INSTANCE_URL: "https://git.luke-else.co.uk"
GITEA_RUNNER_REGISTRATION_TOKEN: "INSERT REGISTRATION TOKEN"
GITEA_RUNNER_REGISTRATION_TOKEN: "${GITEA_RUNNER_REGISTRATION_TOKEN}"
GITEA_RUNNER_NAME: "CICD#1"
labels:
## Expose cicd Through Trefik ##
- "traefik.enable=true" # <== Enable traefik to proxy this container
- "traefik.http.middlewares.redirect-web-secure.redirectscheme.scheme=https"
- "traefik.http.routers.cicd-insecure.middlewares=redirect-web-secure"
- "traefik.http.routers.cicd-insecure.rule=Host(`cicd.luke-else.co.uk`)"
- "traefik.http.routers.cicd-insecure.entrypoints=web"
- "traefik.http.routers.cicd.rule=Host(`cicd.luke-else.co.uk`)"
- "traefik.http.routers.cicd.entrypoints=websecure"
- "traefik.http.routers.cicd.tls.certresolver=myresolver"
restart: unless-stopped
networks:
+1
View File
@@ -6,6 +6,7 @@ cd Runners
docker compose down
cd ..
docker compose -f gitea-docker-compose.yml down
docker compose -f traefik-docker-compose.yml down
docker compose -f watchtower-docker-compose.yml down
+16
View File
@@ -5,6 +5,22 @@ cd "$(dirname "$0")"
docker compose -f traefik-docker-compose.yml pull && docker compose -f traefik-docker-compose.yml up -d
docker compose -f gitea-docker-compose.yml pull && docker compose -f gitea-docker-compose.yml up -d
echo "Waiting for Gitea to become ready..."
for i in $(seq 1 30); do
if docker exec gitea gitea admin user list >/dev/null 2>&1; then
break
fi
sleep 2
done
# Generate a fresh Actions runner registration token straight from Gitea and
# hand it to the runner containers via .env (docker compose auto-loads this) -
# no manual copy/paste from the admin UI needed.
RUNNER_TOKEN=$(docker exec gitea gitea actions generate-runner-token)
echo "GITEA_RUNNER_REGISTRATION_TOKEN=$RUNNER_TOKEN" > Runners/.env
cd Runners
docker compose pull && docker compose up -d
cd ..
-4
View File
@@ -21,10 +21,6 @@
- Ensure that ports are assigned correctly for the system
# Gitea Runner
- Ensure that a registration token has been setup before continuing
## Websites
- Ensure website files are copied over