2023-05-28 17:08:30 +02:00
|
|
|
# Configuration du service "admin"
|
2023-04-24 20:52:12 +02:00
|
|
|
admin:
|
2024-02-05 15:54:10 +01:00
|
|
|
http:
|
|
|
|
# Hôte d'écoute du service,
|
|
|
|
# 0.0.0.0 pour écouter sur toutes les interfaces
|
|
|
|
host: 127.0.0.1
|
|
|
|
# Port d'écoute du service
|
|
|
|
port: 8081
|
|
|
|
# Utiliser les entêtes HTTP True-Client-IP, X-Real-IP ou X-Forwarded-For
|
|
|
|
# pour le calcul de l'adresse distante à l'origine des requêtes
|
|
|
|
useRealIP: true
|
2023-05-28 17:08:30 +02:00
|
|
|
|
2024-02-05 15:54:10 +01:00
|
|
|
# Configuration CORS du service
|
|
|
|
# Uniquement nécessaire si un frontend web
|
|
|
|
# est branché sur l'API d'administration.
|
|
|
|
cors:
|
|
|
|
allowedOrigins:
|
|
|
|
- http://localhost:8081
|
|
|
|
allowCredentials: true
|
|
|
|
allowMethods:
|
|
|
|
- POST
|
|
|
|
- GET
|
|
|
|
- PUT
|
|
|
|
- DELETE
|
|
|
|
allowedHeaders:
|
|
|
|
- Origin
|
|
|
|
- Accept
|
|
|
|
- Content-Type
|
|
|
|
- Authorization
|
|
|
|
- Sentry-Trace
|
|
|
|
debug: false
|
2023-05-28 17:08:30 +02:00
|
|
|
|
2024-02-05 15:54:10 +01:00
|
|
|
# Authentification JWT
|
|
|
|
auth:
|
|
|
|
# Origine du jeton JWT
|
|
|
|
issuer: http://127.0.0.1:8081
|
|
|
|
# Clé privée permettant de signer les jetons
|
|
|
|
# JWT générés pour l'usage de l'API d'administration.
|
|
|
|
privateKey: /etc/bouncer/admin-key.json
|
|
|
|
|
|
|
|
# Métriques Prometheus
|
|
|
|
metrics:
|
|
|
|
# Activer ou désactiver la publication des métriques
|
|
|
|
enabled: true
|
|
|
|
# Route de publication des métriques
|
|
|
|
endpoint: /.bouncer/metrics
|
|
|
|
# Authentification "basic auth" sur la page
|
|
|
|
# de publication
|
|
|
|
# Mettre à null pour désactiver l'authentification
|
|
|
|
basicAuth: null
|
|
|
|
|
|
|
|
# Configuration de l'intégration Sentry
|
|
|
|
# Voir https://pkg.go.dev/github.com/getsentry/sentry-go?utm_source=godoc#ClientOptions
|
|
|
|
sentry:
|
|
|
|
dsn: ""
|
|
|
|
debug: false
|
|
|
|
flushTimeout: 2s
|
|
|
|
attachStacktrace: true
|
|
|
|
sampleRate: 1
|
|
|
|
enableTracing: true
|
|
|
|
tracesSampleRate: 0.2
|
|
|
|
profilesSampleRate: 1
|
|
|
|
ignoreErrors: []
|
|
|
|
sendDefaultPII: false
|
|
|
|
serverName: ""
|
|
|
|
environment: ""
|
|
|
|
maxBreadcrumbs: 0
|
|
|
|
maxSpans: 1000
|
|
|
|
maxErrorDepth: 10
|
2023-07-01 01:51:01 +02:00
|
|
|
|
2023-05-28 17:08:30 +02:00
|
|
|
# Configuration du service "proxy"
|
2023-04-24 20:52:12 +02:00
|
|
|
proxy:
|
2024-02-05 15:54:10 +01:00
|
|
|
http:
|
|
|
|
# Hôte d'écoute du service,
|
|
|
|
# 0.0.0.0 pour écouter sur toutes les interfaces
|
|
|
|
host: 0.0.0.0
|
|
|
|
# Port d'écoute du service
|
|
|
|
port: 8080
|
|
|
|
# Utiliser les entêtes HTTP True-Client-IP, X-Real-IP ou X-Forwarded-For
|
|
|
|
# pour le calcul de l'adresse distante à l'origine des requêtes
|
|
|
|
useRealIP: true
|
|
|
|
|
|
|
|
# Métriques Prometheus
|
|
|
|
metrics:
|
|
|
|
# Activer ou désactiver la publication des métriques
|
|
|
|
enabled: true
|
|
|
|
# Route de publication des métriques
|
|
|
|
endpoint: /.bouncer/metrics
|
|
|
|
# Authentification "basic auth" sur la page
|
|
|
|
# de publication
|
|
|
|
# Mettre à null pour désactiver l'authentification
|
|
|
|
basicAuth:
|
|
|
|
credentials:
|
|
|
|
prom: etheus
|
2023-07-01 21:47:34 +02:00
|
|
|
|
2024-02-05 15:54:10 +01:00
|
|
|
# Configuration du transport HTTP(S)
|
|
|
|
# Voir https://pkg.go.dev/net/http#Transport
|
|
|
|
transport:
|
|
|
|
forceAttemptHTTP2: true
|
|
|
|
maxIdleConns: 100
|
|
|
|
maxIdleConnsPerHost: 100
|
|
|
|
maxConnsPerHost: 100
|
|
|
|
idleConnTimeout: 1m30s
|
|
|
|
tlsHandshakeTimeout: 10s
|
|
|
|
expectContinueTimeout: 1s
|
|
|
|
disableKeepAlives: false
|
|
|
|
disableCompression: false
|
|
|
|
responseHeaderTimeout: 10s
|
|
|
|
writeBufferSize: 4096
|
|
|
|
readBufferSize: 4096
|
|
|
|
maxResponseHeaderBytes: 0
|
2023-07-01 21:47:34 +02:00
|
|
|
|
2024-02-05 15:54:10 +01:00
|
|
|
# Configuration de l'intégration Sentry
|
|
|
|
# Voir https://pkg.go.dev/github.com/getsentry/sentry-go?utm_source=godoc#ClientOptions
|
|
|
|
sentry:
|
|
|
|
dsn: ""
|
|
|
|
debug: false
|
|
|
|
flushTimeout: 2s
|
|
|
|
attachStacktrace: true
|
|
|
|
sampleRate: 1
|
|
|
|
enableTracing: true
|
|
|
|
tracesSampleRate: 0.2
|
|
|
|
profilesSampleRate: 1
|
|
|
|
ignoreErrors: []
|
|
|
|
sendDefaultPII: false
|
|
|
|
serverName: ""
|
|
|
|
environment: ""
|
|
|
|
maxBreadcrumbs: 0
|
|
|
|
maxSpans: 1000
|
|
|
|
maxErrorDepth: 10
|
2023-07-05 20:05:30 +02:00
|
|
|
|
2024-02-05 15:54:10 +01:00
|
|
|
# Configuration des connexions TCP
|
|
|
|
# Voir https://pkg.go.dev/net#Dialer
|
|
|
|
dial:
|
|
|
|
timeout: 30s
|
|
|
|
keepAlive: 30s
|
|
|
|
fallbackDelay: 300ms
|
|
|
|
dualStack: true
|
2023-05-28 17:08:30 +02:00
|
|
|
|
|
|
|
# Configuration du client Redis
|
|
|
|
#
|
|
|
|
# Les modes "standalone", "sentinel" et "cluster" de Redis sont supportés:
|
|
|
|
# - Mode "standalone": renseigner une seule entrée dans redis.addresses;
|
2024-02-05 15:54:10 +01:00
|
|
|
# - Mode "sentinel": renseigner le nom du master sentinel dans redis.master et une ou plusieurs adresses dans redis.addresses;
|
2023-05-28 17:08:30 +02:00
|
|
|
# - Mode "cluster": renseigner plusieurs adresses dans redis.addresses et laisser redis.master vide.
|
2023-05-28 15:41:40 +02:00
|
|
|
redis:
|
2024-02-05 15:54:10 +01:00
|
|
|
addresses:
|
|
|
|
- localhost:6379
|
|
|
|
master: ""
|
2024-02-15 15:17:57 +01:00
|
|
|
writeTimeout: 30s
|
|
|
|
readTimeout: 30s
|
|
|
|
dialTimeout: 30s
|
2023-05-28 17:08:30 +02:00
|
|
|
|
|
|
|
# Configuration des logs
|
2023-04-24 20:52:12 +02:00
|
|
|
logger:
|
2024-02-05 15:54:10 +01:00
|
|
|
# Niveau de verbosité
|
|
|
|
# 0 - DEBUG
|
|
|
|
# 1 - INFO
|
|
|
|
# 2 - WARNING
|
|
|
|
# 3 - ERROR
|
|
|
|
# 4 - FATAL
|
|
|
|
level: 1
|
|
|
|
# Format des logs, "human" ou "json"
|
|
|
|
format: human
|
2023-06-13 03:57:13 +02:00
|
|
|
|
|
|
|
# Configuration des différents layers
|
|
|
|
layers:
|
2024-02-05 15:54:10 +01:00
|
|
|
# Configuration du layer "queue"
|
|
|
|
queue:
|
|
|
|
# Répertoire contenant les templates
|
|
|
|
templateDir: "/etc/bouncer/layers/queue/templates"
|
|
|
|
# Temps de vie par défaut d'une session
|
|
|
|
defaultKeepAlive: 1m
|
|
|
|
|
|
|
|
# Configuration du layer "circuitbreaker"
|
|
|
|
circuitbreaker:
|
|
|
|
# Répertoire contenant les templates
|
|
|
|
templateDir: "/etc/bouncer/layers/circuitbreaker/templates"
|
|
|
|
|