mirror of
https://github.com/SamyRai/turash.git
synced 2025-12-26 23:01:33 +00:00
feat: Add Gitea Actions runners configuration
All checks were successful
CI/CD Pipeline / frontend-lint (push) Has been skipped
CI/CD Pipeline / backend-lint (push) Has been skipped
CI/CD Pipeline / frontend-build (push) Has been skipped
CI/CD Pipeline / backend-build (push) Has been skipped
CI/CD Pipeline / e2e-test (push) Has been skipped
All checks were successful
CI/CD Pipeline / frontend-lint (push) Has been skipped
CI/CD Pipeline / backend-lint (push) Has been skipped
CI/CD Pipeline / frontend-build (push) Has been skipped
CI/CD Pipeline / backend-build (push) Has been skipped
CI/CD Pipeline / e2e-test (push) Has been skipped
This commit is contained in:
parent
b4715361cd
commit
bb8a57e2a7
9
k8s/gitea-runners/configmap.yaml
Normal file
9
k8s/gitea-runners/configmap.yaml
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: gitea-runner-config
|
||||||
|
namespace: gitea-runners
|
||||||
|
data:
|
||||||
|
GITEA_URL: "https://gitea.bk.glpx.pro"
|
||||||
|
GITEA_TOKEN: "" # Will be set from secret
|
||||||
|
|
||||||
64
k8s/gitea-runners/deployment.yaml
Normal file
64
k8s/gitea-runners/deployment.yaml
Normal file
@ -0,0 +1,64 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: gitea-runner
|
||||||
|
namespace: gitea-runners
|
||||||
|
labels:
|
||||||
|
app: gitea-runner
|
||||||
|
spec:
|
||||||
|
replicas: 4
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: gitea-runner
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: gitea-runner
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: docker-daemon
|
||||||
|
image: docker:dind
|
||||||
|
env:
|
||||||
|
- name: DOCKER_TLS_CERTDIR
|
||||||
|
value: ""
|
||||||
|
securityContext:
|
||||||
|
privileged: true
|
||||||
|
volumeMounts:
|
||||||
|
- name: docker-graph-storage
|
||||||
|
mountPath: /var/lib/docker
|
||||||
|
- name: runner
|
||||||
|
image: gitea/act_runner:latest
|
||||||
|
env:
|
||||||
|
- name: GITEA_INSTANCE_URL
|
||||||
|
value: "http://gitea.gitea.svc.cluster.local:3000"
|
||||||
|
- name: GITEA_RUNNER_REGISTRATION_TOKEN
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: gitea-runner-secret
|
||||||
|
key: GITEA_RUNNER_REGISTRATION_TOKEN
|
||||||
|
- name: GITEA_RUNNER_NAME
|
||||||
|
valueFrom:
|
||||||
|
fieldRef:
|
||||||
|
fieldPath: metadata.name
|
||||||
|
- name: GITEA_RUNNER_LABELS
|
||||||
|
value: "ubuntu-latest:docker://node:18-bullseye,ubuntu-22.04:docker://node:18-bullseye,ubuntu-20.04:docker://node:18-bullseye"
|
||||||
|
- name: DOCKER_HOST
|
||||||
|
value: "tcp://localhost:2375"
|
||||||
|
volumeMounts:
|
||||||
|
- name: runner-data
|
||||||
|
mountPath: /data
|
||||||
|
- name: docker-graph-storage
|
||||||
|
mountPath: /var/lib/docker
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
memory: "512Mi"
|
||||||
|
cpu: "250m"
|
||||||
|
limits:
|
||||||
|
memory: "2Gi"
|
||||||
|
cpu: "2000m"
|
||||||
|
volumes:
|
||||||
|
- name: runner-data
|
||||||
|
emptyDir: {}
|
||||||
|
- name: docker-graph-storage
|
||||||
|
emptyDir: {}
|
||||||
|
dnsPolicy: ClusterFirst
|
||||||
7
k8s/gitea-runners/namespace.yaml
Normal file
7
k8s/gitea-runners/namespace.yaml
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: gitea-runners
|
||||||
|
labels:
|
||||||
|
name: gitea-runners
|
||||||
|
|
||||||
9
k8s/gitea-runners/secret.yaml.template
Normal file
9
k8s/gitea-runners/secret.yaml.template
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Secret
|
||||||
|
metadata:
|
||||||
|
name: gitea-runner-secret
|
||||||
|
namespace: gitea-runners
|
||||||
|
type: Opaque
|
||||||
|
stringData:
|
||||||
|
GITEA_RUNNER_REGISTRATION_TOKEN: "YOUR_REGISTRATION_TOKEN_HERE"
|
||||||
|
|
||||||
Loading…
Reference in New Issue
Block a user