From 52b952be0f8795fdb9ea44d829b718ecc48e0ed0 Mon Sep 17 00:00:00 2001 From: xyhhx Date: Tue, 28 Nov 2023 01:08:54 +0000 Subject: [PATCH] docs(example/kubernetes): use pod names as runner names --- examples/kubernetes/dind-docker.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/examples/kubernetes/dind-docker.yaml b/examples/kubernetes/dind-docker.yaml index 0dd0aea..44386b8 100644 --- a/examples/kubernetes/dind-docker.yaml +++ b/examples/kubernetes/dind-docker.yaml @@ -39,8 +39,12 @@ spec: initContainers: - name: runner-register image: code.forgejo.org/forgejo/runner:3.2.0 - command: ["forgejo-runner", "register", "--no-interactive", "--token", $(RUNNER_SECRET), "--name", "runner", "--instance", $(FORGEJO_INSTANCE_URL)] + command: ["forgejo-runner", "register", "--no-interactive", "--token", $(RUNNER_SECRET), "--name", $(RUNNER_NAME), "--instance", $(FORGEJO_INSTANCE_URL)] env: + - name: RUNNER_NAME + valueFrom: + fieldRef: + fieldPath: metadata.name - name: RUNNER_SECRET valueFrom: secretKeyRef: