This commit is contained in:
2026-05-12 21:44:34 +02:00
commit 2379497cb7
7 changed files with 107 additions and 0 deletions

6
Caddyfile Normal file
View File

@@ -0,0 +1,6 @@
git.melosh.tech {
reverse_proxy https://pokerogue.net/ {
header_up Host {upstream_hostport}
header_up X-Real-IP {remote_host}
}
}

5
Containerfile Normal file
View File

@@ -0,0 +1,5 @@
FROM docker.io/caddy:2-alpine
COPY ./Caddyfile /etc/caddy/Caddyfile
CMD [ "caddy", "run" ]

12
deploy/cert.yaml Normal file
View File

@@ -0,0 +1,12 @@
apiVersion: cert-manager.io/v1
kind: Certificate
metadata:
name: douwsky-proxy
spec:
secretName: douwsky-proxy
issuerRef:
name: letsencrypt-prod # This must match your ClusterIssuer name
kind: ClusterIssuer
dnsNames:
- git.melosh.tech

41
deploy/deployment.yaml Normal file
View File

@@ -0,0 +1,41 @@
# https://kubernetes.io/docs/concepts/workloads/controllers/deployment/
apiVersion: apps/v1
kind: Deployment
metadata:
name: douwsky-proxy
labels:
app: douwsky-proxy
spec:
selector:
matchLabels:
app: douwsky-proxy
replicas: 1
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
annotations:
kubectl.kubernetes.io/default-container: douwsky-proxy
labels:
app: douwsky-proxy
spec:
containers:
- name: douwsky-proxy
image: registry.milasholsting.dk/douwsky/proxy
imagePullPolicy: always
resources:
requests:
cpu: 100m
memory: 100Mi
limits:
cpu: 100m
memory: 100Mi
ports:
- containerPort: 80
name: myjob
restartPolicy: Always
---

20
deploy/ingress.yaml Normal file
View File

@@ -0,0 +1,20 @@
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
name: douwsky-proxy
spec:
entryPoints:
- websecure
routes:
- kind: Rule
match: Host(`git.melosh.tech`)
priority: 10
services:
- name: douwsky-proxy
port: 80
tls:
secretName: douwsky-proxy
domains:
- main: git.melosh.tech

View File

@@ -0,0 +1,7 @@
namespace: douwsky
resources:
- ./cert.yaml
- ./deployment.yaml
- ./ingress.yaml
- ./service.yaml

16
deploy/service.yaml Normal file
View File

@@ -0,0 +1,16 @@
# https://kubernetes.io/docs/concepts/services-networking/service/
apiVersion: v1
kind: Service
metadata:
name: douwsky-proxy
spec:
selector:
app: douwsky-proxy
type: clusterIP
ports:
- name: douwsky-proxy
protocol:
port: 80
targetPort: 80
---