summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEarl Warren <contact@earl-warren.org>2025-01-15 11:41:24 +0100
committerEarl Warren <contact@earl-warren.org>2025-01-15 12:24:32 +0100
commit564134560b84aabf6832787a98b2dbc04ad45f9c (patch)
treedc2b9f10ff69d94b0f6a88fb44516cd1203d95c9
parentMerge pull request 'Update actions/setup-forgejo action to v2.0.5' (#430) fro... (diff)
downloadforgejo-runner-564134560b84aabf6832787a98b2dbc04ad45f9c.tar.xz
forgejo-runner-564134560b84aabf6832787a98b2dbc04ad45f9c.zip
fix: example uses code.forgejo.org/oci
Otherwise it may get rate limited in the CI verifying it works
-rw-r--r--examples/docker-compose/README.md5
-rw-r--r--examples/docker-compose/compose-demo-workflow.yml6
-rw-r--r--examples/docker-compose/compose-forgejo-and-runner.yml8
-rw-r--r--examples/docker/README.md4
-rw-r--r--examples/kubernetes/dind-docker.yaml4
5 files changed, 14 insertions, 13 deletions
diff --git a/examples/docker-compose/README.md b/examples/docker-compose/README.md
index a3e6e9b..ccb0f72 100644
--- a/examples/docker-compose/README.md
+++ b/examples/docker-compose/README.md
@@ -80,8 +80,9 @@ A new repository is created in root/test with the following workflows:
on: [push]
jobs:
test:
- runs-on: docker
+ runs-on: node-bookworm
steps:
+ - uses: https://code.forgejo.org/actions/checkout@v4
- run: echo All Good
```
@@ -91,7 +92,7 @@ jobs:
on: [push]
jobs:
test_docker:
- runs-on: ubuntu-22.04
+ runs-on: docker-cli
steps:
- run: docker info
```
diff --git a/examples/docker-compose/compose-demo-workflow.yml b/examples/docker-compose/compose-demo-workflow.yml
index 90e7d52..7f7beaa 100644
--- a/examples/docker-compose/compose-demo-workflow.yml
+++ b/examples/docker-compose/compose-demo-workflow.yml
@@ -4,7 +4,7 @@
services:
demo-workflow:
- image: code.forgejo.org/oci/alpine:3.19
+ image: code.forgejo.org/oci/alpine:3.21
links:
- forgejo
command: >-
@@ -14,8 +14,8 @@ services:
cd /srv/demo ;
git init --initial-branch=main ;
mkdir -p .forgejo/workflows ;
- echo "{ on: [push], jobs: { test: { runs-on: docker, steps: [ {uses: actions/checkout@v4}, { run: echo All Good } ] } } }" > .forgejo/workflows/demo.yml ;
- echo "{ on: [push], jobs: { test_docker: { runs-on: ubuntu-22.04, steps: [ { run: docker info } ] } } }" > .forgejo/workflows/demo_docker.yml ;
+ echo "{ on: [push], jobs: { test: { runs-on: node-bookworm, steps: [ {uses: https://code.forgejo.org/actions/checkout@v4}, { run: echo All Good } ] } } }" > .forgejo/workflows/demo.yml ;
+ echo "{ on: [push], jobs: { test_docker: { runs-on: docker-cli, steps: [ { run: docker info, shell: sh } ] } } }" > .forgejo/workflows/demo_docker.yml ;
git add . ;
git config user.email root@example.com ;
git config user.name username ;
diff --git a/examples/docker-compose/compose-forgejo-and-runner.yml b/examples/docker-compose/compose-forgejo-and-runner.yml
index 222dbe9..4028d08 100644
--- a/examples/docker-compose/compose-forgejo-and-runner.yml
+++ b/examples/docker-compose/compose-forgejo-and-runner.yml
@@ -30,7 +30,7 @@ services:
- docker_certs:/certs
forgejo:
- image: codeberg.org/forgejo/forgejo:1.21
+ image: codeberg.org/forgejo/forgejo:9.0
command: >-
bash -c '
/bin/s6-svscan /etc/s6 &
@@ -51,7 +51,7 @@ services:
- 8080:3000
runner-register:
- image: code.forgejo.org/forgejo/runner:5.0.4
+ image: code.forgejo.org/forgejo/runner:6.0.1
links:
- docker-in-docker
- forgejo
@@ -66,7 +66,7 @@ services:
forgejo-runner create-runner-file --connect --instance http://forgejo:3000 --name runner --secret {SHARED_SECRET} && break ;
sleep 1 ;
done ;
- sed -i -e "s|\"labels\": null|\"labels\": [\"docker:docker://code.forgejo.org/oci/node:20-bookworm\", \"ubuntu-22.04:docker://catthehacker/ubuntu:act-22.04\"]|" .runner ;
+ sed -i -e "s|\"labels\": null|\"labels\": [\"docker-cli:docker://code.forgejo.org/oci/docker:cli\",\"node-bookworm:docker://code.forgejo.org/oci/node:20-bookworm\"]|" .runner ;
forgejo-runner generate-config > config.yml ;
sed -i -e "s| level: info| level: debug|" config.yml ;
sed -i -e "s|network: .*|network: host|" config.yml ;
@@ -77,7 +77,7 @@ services:
'
runner-daemon:
- image: code.forgejo.org/forgejo/runner:5.0.4
+ image: code.forgejo.org/forgejo/runner:6.0.1
links:
- docker-in-docker
- forgejo
diff --git a/examples/docker/README.md b/examples/docker/README.md
index 9131559..a439dbd 100644
--- a/examples/docker/README.md
+++ b/examples/docker/README.md
@@ -6,7 +6,7 @@ The following assumes:
* a `runner-config.yml` file exists in /tmp/data
```sh
-docker run -v /var/run/docker.sock:/var/run/docker.sock -v /tmp/data:/data --user 1000:133 --rm code.forgejo.org/forgejo/runner:5.0.4 forgejo-runner --config runner-config.yaml daemon
+docker run -v /var/run/docker.sock:/var/run/docker.sock -v /tmp/data:/data --user 1000:133 --rm code.forgejo.org/forgejo/runner:6.0.1 forgejo-runner --config runner-config.yaml daemon
```
-The workflows will run using the host docker srever
+The workflows will run using the host docker server
diff --git a/examples/kubernetes/dind-docker.yaml b/examples/kubernetes/dind-docker.yaml
index 7f51a0a..4dd2979 100644
--- a/examples/kubernetes/dind-docker.yaml
+++ b/examples/kubernetes/dind-docker.yaml
@@ -38,7 +38,7 @@ spec:
# https://forgejo.org/docs/v1.21/admin/actions/#offline-registration
initContainers:
- name: runner-register
- image: code.forgejo.org/forgejo/runner:5.0.4
+ image: code.forgejo.org/forgejo/runner:6.0.1
command: ["forgejo-runner", "register", "--no-interactive", "--token", $(RUNNER_SECRET), "--name", $(RUNNER_NAME), "--instance", $(FORGEJO_INSTANCE_URL)]
env:
- name: RUNNER_NAME
@@ -61,7 +61,7 @@ spec:
mountPath: /data
containers:
- name: runner
- image: code.forgejo.org/forgejo/runner:5.0.4
+ image: code.forgejo.org/forgejo/runner:6.0.1
command: ["sh", "-c", "while ! nc -z localhost 2376 </dev/null; do echo 'waiting for docker daemon...'; sleep 5; done; forgejo-runner daemon"]
env:
- name: DOCKER_HOST