cloudflare tunnel ingress
All checks were successful
Apply Kuberentes Configs / update-repo (push) Successful in 0s
Apply Kuberentes Configs / update-infrastructure (push) Successful in 3s
Apply Kuberentes Configs / notify-on-failure (push) Has been skipped

This commit is contained in:
2026-03-05 09:28:52 -07:00
parent b074a02edf
commit 7242f64b0c
2 changed files with 51 additions and 0 deletions

View File

@@ -50,6 +50,13 @@ jobs:
kubectl apply -f kubernetes/homepage/
kubectl rollout restart deployment/homepage -n homepage
- name: gitea
env:
CLOUDFLARED_GITEA_TOKEN: ${{ secrets.CLOUDFLARED_GITEA_TOKEN }}
run: |
for file in kubernetes/gitea/*.yml; do
cat "$file" | envsubst | kubectl apply -f -
done
notify-on-failure:
runs-on: home-server

View File

@@ -0,0 +1,44 @@
apiVersion: v1
kind: Secret
metadata:
name: cloudflared-gitea-token
namespace: gitea
type: Opaque
stringData:
token: $CLOUDFLARED_GITEA_TOKEN
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: cloudflared-gitea
namespace: gitea
spec:
replicas: 1
selector:
matchLabels:
app: cloudflared-gitea
template:
metadata:
labels:
app: cloudflared-gitea
spec:
containers:
- name: cloudflared
image: cloudflare/cloudflared:latest
imagePullPolicy: Always
args:
- tunnel
- run
env:
- name: TUNNEL_TOKEN
valueFrom:
secretKeyRef:
name: cloudflared-gitea-token
key: token
livenessProbe:
httpGet:
path: /ready
port: 2000
failureThreshold: 1
initialDelaySeconds: 10
periodSeconds: 10