1
0
Fork 0
mirror of https://code.forgejo.org/infrastructure/documentation synced 2024-11-28 21:31:10 +00:00

next.forgejo.org: no more than 10 request per second

This commit is contained in:
Earl Warren 2024-10-22 10:21:54 +02:00
parent b40fd5bd3c
commit 0f9b5ff8e2
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00

View file

@ -5,6 +5,10 @@ image:
rootless: false
ingress:
annotations:
# https://doc.traefik.io/traefik/v2.10/routing/providers/kubernetes-ingress/#on-ingress
# reference middlewares via `<namspace>-<name>@kubernetescrd`
traefik.ingress.kubernetes.io/router.middlewares: default-forgejo-ratelimit@kubernetescrd
tls:
- hosts:
- next.forgejo.org
@ -20,6 +24,15 @@ service:
port: 2222
extraDeploy:
- apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: forgejo-ratelimit
spec:
# https://doc.traefik.io/traefik/v2.10/middlewares/http/ratelimit/
rateLimit:
average: 10
burst: 20
# Route from traefik to forgejo
- apiVersion: traefik.io/v1alpha1
kind: IngressRouteTCP