Skip to content

Commit

Permalink
fix keycloak secrets drift
Browse files Browse the repository at this point in the history
  • Loading branch information
klinch0 authored and kvaps committed Dec 4, 2024
1 parent 7da85d6 commit b5262ea
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/system/keycloak/templates/sts.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
{{- $cozyConfig := lookup "v1" "ConfigMap" "cozy-system" "cozystack" }}
{{- $host := index $cozyConfig.data "root-host" }}

{{- $existingPassword := lookup "v1" "Secret" "cozy-keycloak" "{{ .Release.Name }}-credentials" }}
{{- $password := randAlphaNum 16 -}}
{{- if $existingPassword }}
{{- $password = index $existingPassword.data "password" | b64dec }}
{{- end }}

apiVersion: v1
kind: Secret
Expand Down

0 comments on commit b5262ea

Please sign in to comment.