diff --git a/charts/netbox/templates/NOTES.txt b/charts/netbox/templates/NOTES.txt index cc3d1f30..fb487576 100644 --- a/charts/netbox/templates/NOTES.txt +++ b/charts/netbox/templates/NOTES.txt @@ -35,8 +35,8 @@ Get the application URL by running these commands: export SERVICE_IP=$(kubectl get svc --namespace {{ include "common.names.namespace" . | quote }} {{ include "common.names.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}') echo http://$SERVICE_IP:{{ .Values.service.port }} - NOTE: It may take a few minutes for the LoadBalancer IP to be available. - You can watch the status of by running 'kubectl get --namespace {{ include "common.names.namespace" . | quote }} svc -w {{ include "common.names.fullname" . }}' + NOTE: It may take a few minutes for the LoadBalancer IP to be available. + You can watch the status of by running 'kubectl get --namespace {{ include "common.names.namespace" . | quote }} svc -w {{ include "common.names.fullname" . }}' {{- else if contains "ClusterIP" .Values.service.type }} @@ -52,9 +52,3 @@ Get the application URL by running these commands: {{- include "common.warnings.rollingTag" .Values.image }} {{- include "common.warnings.rollingTag" .Values.init.image }} {{- include "common.warnings.resources" (dict "sections" (list "" "worker") "context" $) }} -{{- $passwordValidationErrors := list -}} -{{- if not .Values.superuser.existingSecret -}} - {{- $superuserPasswordValidationErrors := include "common.validations.values.single.empty" (dict "valueKey" "superuser.password" "secret" (include "common.secrets.name" (dict "defaultNameSuffix" "superuser" "context" .)) "field" "password" "context" $) -}} - {{- $passwordValidationErrors = append $passwordValidationErrors $superuserPasswordValidationErrors -}} -{{- end }} -{{- include "common.errors.upgrade.passwords.empty" (dict "validationErrors" $passwordValidationErrors "context" $) -}} diff --git a/charts/netbox/templates/superuser-secrets.yaml b/charts/netbox/templates/superuser-secrets.yaml index 46474e1a..978c5277 100644 --- a/charts/netbox/templates/superuser-secrets.yaml +++ b/charts/netbox/templates/superuser-secrets.yaml @@ -11,7 +11,7 @@ metadata: type: kubernetes.io/basic-auth data: username: {{ .Values.superuser.name | default "admin" | b64enc | quote }} - password: {{ .Values.superuser.password | default (randAlphaNum 16) | b64enc | quote }} + password: {{ include "common.secrets.passwords.manage" (dict "secret" (include "common.secrets.name" (dict "defaultNameSuffix" "superuser" "context" $)) "key" "password" "providedValues" (list "superuser.password") "context" $) }} email: {{ .Values.superuser.email | b64enc | quote }} api_token: {{ .Values.superuser.apiToken | default uuidv4 | b64enc | quote }} {{- end -}}