Initial commit
This commit is contained in:
56
infrastructure/routes/gitea.yaml
Normal file
56
infrastructure/routes/gitea.yaml
Normal file
@@ -0,0 +1,56 @@
|
||||
# Gitea ingress routes via Traefik.
|
||||
# Replace <YOUR_DOMAIN> with your domain (e.g. git.example.com).
|
||||
---
|
||||
apiVersion: traefik.io/v1alpha1
|
||||
kind: Middleware
|
||||
metadata:
|
||||
name: redirect-https
|
||||
namespace: gitea
|
||||
spec:
|
||||
redirectScheme:
|
||||
scheme: https
|
||||
permanent: true
|
||||
---
|
||||
# HTTP entrypoint — redirects all traffic to HTTPS
|
||||
apiVersion: traefik.io/v1alpha1
|
||||
kind: IngressRoute
|
||||
metadata:
|
||||
name: gitea-ingress-http
|
||||
namespace: gitea
|
||||
spec:
|
||||
entryPoints:
|
||||
- web
|
||||
routes:
|
||||
- match: Host(`<YOUR_DOMAIN>`)
|
||||
kind: Rule
|
||||
middlewares:
|
||||
- name: redirect-https
|
||||
services:
|
||||
- name: gitea-http
|
||||
namespace: gitea
|
||||
port: 3000
|
||||
---
|
||||
# HTTPS entrypoint — serves Gitea with TLS
|
||||
apiVersion: traefik.io/v1alpha1
|
||||
kind: IngressRoute
|
||||
metadata:
|
||||
name: gitea-ingress
|
||||
namespace: gitea
|
||||
annotations:
|
||||
cert-manager.io/issuer: "cert-issuer"
|
||||
spec:
|
||||
entryPoints:
|
||||
- websecure
|
||||
routes:
|
||||
- match: Host(`<YOUR_DOMAIN>`)
|
||||
kind: Rule
|
||||
services:
|
||||
- name: gitea-http
|
||||
namespace: gitea
|
||||
port: 3000
|
||||
tls:
|
||||
secretName: gitea-tls
|
||||
domains:
|
||||
- main: <YOUR_DOMAIN>
|
||||
sans:
|
||||
- <YOUR_DOMAIN>
|
||||
Reference in New Issue
Block a user