apps/forgejo/resources/runners/act-runner-arm64.yaml
Peter Kurfer a0e3708202
All checks were successful
Renovate / renovate (push) Successful in 15s
feat(forgejo): add amd64 runners
2023-11-30 08:52:15 +01:00

88 lines
No EOL
2.5 KiB
YAML

---
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: act-runner-arm64
spec:
selector:
matchLabels:
app.kubernetes.io/name: act-runner
app.kubernetes.io/instance: arm64
serviceName: act-runner
replicas: 2
template:
metadata:
labels:
app.kubernetes.io/name: act-runner
app.kubernetes.io/instance: arm64
spec:
restartPolicy: Always
initContainers:
- name: runner-registration
image: docker.io/alpine:3.18
command:
- /bin/ash
- -c
- "cp /etc/act/`hostname` /data/.runner"
volumeMounts:
- name: runner-data
mountPath: /data
- name: runner-registrations
mountPath: /etc/act
containers:
- name: runner
image: act_runner
imagePullPolicy: Always
command: ["sh", "-c", "while ! nc -z localhost 2376 </dev/null; do echo 'waiting for docker daemon...'; sleep 5; done; /sbin/tini -- /opt/act/run.sh"]
env:
- name: DOCKER_HOST
value: tcp://localhost:2376
- name: DOCKER_CERT_PATH
value: /certs/client
- name: DOCKER_TLS_VERIFY
value: "1"
- name: CONFIG_FILE
value: /etc/act/config.yaml
volumeMounts:
- name: runner-data
mountPath: /data
- name: runner-config
mountPath: /etc/act
- name: docker-certs
mountPath: /certs
securityContext:
privileged: true
- name: daemon
image: docker:23.0.6-dind
env:
- name: DOCKER_TLS_CERTDIR
value: /certs
securityContext:
privileged: true
volumeMounts:
- name: docker-certs
mountPath: /certs
securityContext:
fsGroup: 1000
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: kubernetes.io/arch
operator: In
values:
- arm64
volumes:
- name: runner-data
emptyDir:
sizeLimit: 500Mi
- name: docker-certs
emptyDir:
sizeLimit: 5Mi
- name: runner-config
configMap:
name: act-runner-config-arm64
- name: runner-registrations
secret:
secretName: runner-registrations