Hello @greenpau , if I understand your examples, does that means that I should perform the following steps :
-
Step 1 : I should replace my reference to the caddy docker image to a locally generated one (using this Docker Caddy v2 and Google oAuth - #9 by francislavoie )
-
Step 2 : generate gitlab credentials (Configure GitLab as an OAuth 2.0 authentication identity provider | GitLab )
-
Step 3 : add generic OAuth in my Caddyfile (will be used by all my endpoints locally)
127.0.0.1, localhost {
route /auth* {
authp {
backends {
generic_oauth2_backend {
method oauth2
realm generic
provider generic
client_id <gitla application ID>
client_secret <gitlab application secret>
scopes openid email profile
}
route /sso/oauth2/generic* {
jwt {
auth_url /auth/oauth2/generic
}
respond * "generic oauth2 sso" 200
}
- Step 4 : modify my enpoints like this :
prometheus.jump.<domain>.com {
jwt {
primary yes
trusted_tokens {
static_secret {
token_name access_token
token_secret <????>
}
}
auth_url /auth
allow roles anonymous guest admin
allow roles superadmin
}
reverse_proxy prometheus:9090
}
alertmanager.jump.<domain>.com {
jwt
reverse_proxy alertmanager:9093
}
=> What value should I use for the token_secret ?
=> Where should I specify witch gitlab groups I am accepting to log in ? (I remember so kind of parameter like this when implementing grafana OAuth).
I feel like I’m missing something… :-/
Thanks in advance for your help !