infra/forgejo: push ci-runner and cut the LAN runner over to it
Some checks failed
PR build (required check) / changes (pull_request) Failing after 6s
secrets-guard / encrypted (pull_request) Failing after 4s
shell-lint / shellcheck (pull_request) Failing after 2s
PR build (required check) / build-backend (pull_request) Has been skipped
PR build (required check) / build-frontend (pull_request) Has been skipped
PR build (required check) / validate-observability (pull_request) Has been skipped
PR build (required check) / gate (pull_request) Successful in 2s
Some checks failed
PR build (required check) / changes (pull_request) Failing after 6s
secrets-guard / encrypted (pull_request) Failing after 4s
shell-lint / shellcheck (pull_request) Failing after 2s
PR build (required check) / build-backend (pull_request) Has been skipped
PR build (required check) / build-frontend (pull_request) Has been skipped
PR build (required check) / validate-observability (pull_request) Has been skipped
PR build (required check) / gate (pull_request) Successful in 2s
Image is live at git.thermograph.org/emi/thermograph/ci-runner:v1. register-lan-runner.sh's LABELS default now points at it, and the live runner's registration was cut over directly (labels edited in ~/forgejo-runner/.runner, no re-registration needed).
This commit is contained in:
parent
c966ac4801
commit
9629994e55
2 changed files with 11 additions and 11 deletions
|
|
@ -122,22 +122,22 @@ rewrite). `ci-runner` is a slim Debian base with `docker-ce-cli` +
|
|||
`python3-yaml` for the other jobs that need them (`shell-lint`,
|
||||
`observability-validate`).
|
||||
|
||||
Built and verified locally; **not yet pushed** — pushing to
|
||||
`git.thermograph.org/emi/thermograph/ci-runner` needs a PAT with
|
||||
`write:package` scope (the embedded git-remote token lacks it, same
|
||||
requirement documented in `backend-build-push.yml`). Once pushed:
|
||||
Pushed as `git.thermograph.org/emi/thermograph/ci-runner:v1`. Rebuild/push
|
||||
(requires a PAT with `write:package` scope — the embedded git-remote token
|
||||
lacks it, same requirement documented in `backend-build-push.yml`):
|
||||
|
||||
```bash
|
||||
docker build -t git.thermograph.org/emi/thermograph/ci-runner:v1 deploy/forgejo/ci-runner
|
||||
docker push git.thermograph.org/emi/thermograph/ci-runner:v1
|
||||
```
|
||||
|
||||
then cut the live runner over by editing the `labels` array in
|
||||
`~/forgejo-runner/.runner` on the desktop (same runner id/token, no
|
||||
re-registration) and updating `register-lan-runner.sh`'s `LABELS` default so
|
||||
future re-provisioning matches. Only after that cutover is verified working
|
||||
should the now-redundant `apt-get install docker.io` / `python3-yaml` steps be
|
||||
removed from the workflows that had them — removing them first would break
|
||||
`register-lan-runner.sh`'s `LABELS` default now points at this image, so
|
||||
fresh registrations pick it up automatically. The live runner is cut over by
|
||||
editing the `labels` array in `~/forgejo-runner/.runner` on the desktop (same
|
||||
runner id/token, no re-registration needed) and restarting the service. Only
|
||||
after a real job has run successfully under the new image should the
|
||||
now-redundant `apt-get install docker.io` / `python3-yaml` steps be removed
|
||||
from the workflows that had them — removing them first would break
|
||||
every job still running on `node:20-bookworm`.
|
||||
|
||||
## Why Postgres here and not the Thermograph app's TimescaleDB
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ set -euo pipefail
|
|||
FORGEJO_URL="${1:?usage: $0 <forgejo_url> <registration_token>}"
|
||||
TOKEN="${2:?}"
|
||||
RUNNER_DIR="${RUNNER_DIR:-$HOME/forgejo-runner}"
|
||||
LABELS="${LABELS:-docker:docker://node:20-bookworm,thermograph-lan}"
|
||||
LABELS="${LABELS:-docker:docker://git.thermograph.org/emi/thermograph/ci-runner:v1,thermograph-lan}"
|
||||
|
||||
echo "==> Stopping and disabling the old GitHub Actions runner service, if present"
|
||||
systemctl --user stop github-actions-runner 2>/dev/null || true
|
||||
|
|
|
|||
Loading…
Reference in a new issue