generated from onedr0p/cluster-template
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(grafana): switch OIDC auth to authentik #191
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
github-actions
bot
added
the
area/kubernetes
Changes made in the kubernetes directory
label
Jan 5, 2024
--- HelmRelease: monitoring/grafana ConfigMap: monitoring/grafana
+++ HelmRelease: monitoring/grafana ConfigMap: monitoring/grafana
@@ -20,24 +20,21 @@
oauth_auto_login = false
[auth.anonymous]
enabled = false
[auth.basic]
enabled = false
[auth.generic_oauth]
- empty_scopes = false
enabled = true
- groups_attribute_path = groups
icon = signin
- login_attribute_path = preferred_username
- name = Authelia
- name_attribute_path = name
- scopes = openid profile email groups
+ name = Authentik
+ scopes = openid profile email
+ skip_org_role_sync = true
use_pkce = true
[auth.generic_oauth.group_mapping]
org_id = 1
- role_attribute_path = contains(groups[*], 'admins') && 'Admin' || contains(groups[*], 'people') && 'Viewer'
+ role_attribute_path = contains(groups[*], 'admins') && 'Admin' || 'Viewer'
[grafana_net]
url = https://grafana.net
[log]
level = debug
mode = console
--- HelmRelease: monitoring/grafana Deployment: monitoring/grafana
+++ HelmRelease: monitoring/grafana Deployment: monitoring/grafana
@@ -221,25 +221,23 @@
value: /var/log/grafana
- name: GF_PATHS_PLUGINS
value: /var/lib/grafana/plugins
- name: GF_PATHS_PROVISIONING
value: /etc/grafana/provisioning
- name: GF_AUTH_GENERIC_OAUTH_API_URL
- value: https://auth.18b.haus/api/oidc/userinfo
+ value: https://identity.18b.haus/application/o/userinfo/
- name: GF_AUTH_GENERIC_OAUTH_AUTH_URL
- value: https://auth.18b.haus/api/oidc/authorization
+ value: https://identity.18b.haus/application/o/authorize/
- name: GF_AUTH_GENERIC_OAUTH_CLIENT_ID
value: grafana
- name: GF_AUTH_GENERIC_OAUTH_TOKEN_URL
- value: https://auth.18b.haus/api/oidc/token
+ value: https://identity.18b.haus/application/o/token/
- name: GF_AUTH_SIGNOUT_REDIRECT_URL
- value: https://auth.18b.haus/logout?rd=https://grafana.18b.haus/login
+ value: https://identity.18b.haus/application/o/grafana/end-session/
- name: GF_EXPLORE_ENABLED
value: 'true'
- - name: GF_SECURITY_COOKIE_SAMESITE
- value: grafana
- name: GF_SERVER_ROOT_URL
value: https://grafana.18b.haus
envFrom:
- secretRef:
name: grafana
optional: false |
--- kubernetes/apps/monitoring/grafana/app Kustomization: flux-system/grafana HelmRelease: monitoring/grafana
+++ kubernetes/apps/monitoring/grafana/app Kustomization: flux-system/grafana HelmRelease: monitoring/grafana
@@ -215,19 +215,18 @@
deleteDatasources:
- name: Prometheus
orgId: 1
deploymentStrategy:
type: Recreate
env:
- GF_AUTH_GENERIC_OAUTH_API_URL: https://auth.18b.haus/api/oidc/userinfo
- GF_AUTH_GENERIC_OAUTH_AUTH_URL: https://auth.18b.haus/api/oidc/authorization
+ GF_AUTH_GENERIC_OAUTH_API_URL: https://identity.18b.haus/application/o/userinfo/
+ GF_AUTH_GENERIC_OAUTH_AUTH_URL: https://identity.18b.haus/application/o/authorize/
GF_AUTH_GENERIC_OAUTH_CLIENT_ID: grafana
- GF_AUTH_GENERIC_OAUTH_TOKEN_URL: https://auth.18b.haus/api/oidc/token
- GF_AUTH_SIGNOUT_REDIRECT_URL: https://auth.18b.haus/logout?rd=https://grafana.18b.haus/login
+ GF_AUTH_GENERIC_OAUTH_TOKEN_URL: https://identity.18b.haus/application/o/token/
+ GF_AUTH_SIGNOUT_REDIRECT_URL: https://identity.18b.haus/application/o/grafana/end-session/
GF_EXPLORE_ENABLED: true
- GF_SECURITY_COOKIE_SAMESITE: grafana
GF_SERVER_ROOT_URL: https://grafana.18b.haus
envFromSecrets:
- name: grafana
grafana.ini:
analytics:
check_for_plugin_updates: false
@@ -238,25 +237,22 @@
oauth_auto_login: false
auth.anonymous:
enabled: false
auth.basic:
enabled: false
auth.generic_oauth:
- empty_scopes: false
enabled: true
- groups_attribute_path: groups
icon: signin
- login_attribute_path: preferred_username
- name: Authelia
- name_attribute_path: name
- scopes: openid profile email groups
+ name: Authentik
+ scopes: openid profile email
+ skip_org_role_sync: true
use_pkce: true
auth.generic_oauth.group_mapping:
org_id: 1
role_attribute_path: |
- contains(groups[*], 'admins') && 'Admin' || contains(groups[*], 'people') && 'Viewer'
+ contains(groups[*], 'admins') && 'Admin' || 'Viewer'
log:
level: debug
news:
news_feed_enabled: false
ingress:
annotations: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Updates #168