From e7d3ddb9b09e96a65fdcb0de678995df8eb8344a Mon Sep 17 00:00:00 2001 From: Mart van Santen Date: Fri, 1 Apr 2022 14:31:03 +0800 Subject: [PATCH] Updated documentation --- .../helmchart/templates/deployment.yaml | 4 +-- deployment/helmchart/templates/ingress.yaml | 15 ++++------ deployment/helmchart/values.yaml | 29 +++++++++++-------- 3 files changed, 25 insertions(+), 23 deletions(-) diff --git a/deployment/helmchart/templates/deployment.yaml b/deployment/helmchart/templates/deployment.yaml index 5584e03..e22ce4f 100644 --- a/deployment/helmchart/templates/deployment.yaml +++ b/deployment/helmchart/templates/deployment.yaml @@ -57,7 +57,7 @@ spec: - name: dashboard securityContext: {{- toYaml .Values.dashboard.containerSecurityContext | nindent 12 }} image: {{ template "dashboard.image" . }} - imagePullPolicy: {{ .Values.dashboard.image.pullPolicy | quote }} + imagePullPolicy: {{ .Values.image.pullPolicy | quote }} {{- if .Values.dashboard.command }} command: {{- include "common.tplvalues.render" (dict "value" .Values.dashboard.command "context" $) | nindent 12 }} {{- end }} @@ -119,7 +119,7 @@ spec: - name: backend securityContext: {{- toYaml .Values.backend.containerSecurityContext | nindent 12 }} image: {{ template "backend.image" . }} - imagePullPolicy: {{ .Values.backend.image.pullPolicy | quote }} + imagePullPolicy: {{ .Values.image.pullPolicy | quote }} {{- if .Values.backend.command }} command: {{- include "common.tplvalues.render" (dict "value" .Values.backend.command "context" $) | nindent 12 }} {{- end }} diff --git a/deployment/helmchart/templates/ingress.yaml b/deployment/helmchart/templates/ingress.yaml index 0b570d3..e60b4fa 100644 --- a/deployment/helmchart/templates/ingress.yaml +++ b/deployment/helmchart/templates/ingress.yaml @@ -1,6 +1,5 @@ {{- if .Values.ingress.enabled -}} -# apiVersion: {{ template "common.capabilities.ingress.apiVersion" . }} -apiVersion: networking.k8s.io/v1 +apiVersion: {{ template "common.capabilities.ingress.apiVersion" . }} kind: Ingress metadata: name: {{ template "common.names.fullname" . }} @@ -63,20 +62,18 @@ spec: number: 80 {{- end }} {{- range .Values.ingress.extraHosts }} + # In the event of "extraHosts", kratos is not proxied. Due the redirects, + # and single domain support of kratos/hydra. it is not feasable to support + # multiple hostnames. Same is true for the /web/ login frontend - host: {{ .name }} http: paths: - - path: ({{ default "/" .path }}.*) + - path: {{ default "/" .path }}(.*) {{- if eq "true" (include "common.ingress.supportsPathType" $) }} pathType: {{ default "ImplementationSpecific" .pathType }} {{- end }} backend: {{- include "common.ingress.backend" (dict "serviceName" (include "dashboard.serviceName" $) "servicePort" "dashboard-http" "context" $) | nindent 14 }} - - path: ({{ default "/" .path }}api/v1.*) - {{- if eq "true" (include "common.ingress.supportsPathType" $) }} - pathType: {{ default "ImplementationSpecific" .pathType }} - {{- end }} - backend: {{- include "common.ingress.backend" (dict "serviceName" (include "backend.serviceName" .) "servicePort" "backend-http" "context" $) | nindent 14 }} - - path: ({{ default "/" .path }}web.*) + - path: {{ default "/" .path }}(api/v1.*) {{- if eq "true" (include "common.ingress.supportsPathType" $) }} pathType: {{ default "ImplementationSpecific" .pathType }} {{- end }} diff --git a/deployment/helmchart/values.yaml b/deployment/helmchart/values.yaml index b7dfba1..39d683b 100644 --- a/deployment/helmchart/values.yaml +++ b/deployment/helmchart/values.yaml @@ -39,9 +39,20 @@ commonAnnotations: {} ## @section Stackspin parameters ## @param imagePullSecrets Specify docker-registry secret names as an array +## @param imagePullPolicy Policy on pulling images on container start ## image: imagePullSecrets: [] + + ## Specify a imagePullPolicy + ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' + ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images + ## + ## Same policy for all containers is used. + ## + # TODO: Set to Always for developoment purposes, should be reverted to + # 'IfNotPresent' + # pullPolicy: IfNotPresent pullPolicy: Always ## Dashboard configuration parameters @@ -61,11 +72,6 @@ dashboard: registry: open.greenhost.net:4567 repository: stackspin/dashboard/dashboard tag: 0-1-6 - ## Specify a imagePullPolicy - ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' - ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images - ## - pullPolicy: IfNotPresent ## Optionally specify an array of imagePullSecrets. ## Secrets must be manually created in the namespace. ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ @@ -226,7 +232,6 @@ backend: ## @param image.registry Stackspin image registry ## @param image.repository Stackspin image repository ## @param image.tag Stackspin image tag - ## @param image.pullPolicy Stackspin image pull policy ## @param image.pullSecrets Stackspin image pull secrets ## @param image.debug Specify if debug logs should be enabled ## @@ -234,11 +239,6 @@ backend: registry: open.greenhost.net:4567 repository: stackspin/dashboard-backend/dashboard-backend tag: 19-integrate-flask-sso-panel-into-dashboard-flask-backend - ## Specify a imagePullPolicy - ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' - ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images - ## - pullPolicy: Always ## Optionally specify an array of imagePullSecrets. ## Secrets must be manually created in the namespace. ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ @@ -257,12 +257,17 @@ backend: authorizationBaseUrl: https://sso.stackspin.example.org/oauth2/auth tokenUrl: https://sso.stackspin.example.org/oauth2/token + # Where to find the Kratos ADMIN and PUBLIC url kratos: publicUrl: https://sso.stackspin.example.org/kratos adminUrl: http://single-sign-on-kratos-admin:80 + + # Where to find the Hydra ADMIN url hydra: adminUrl: http://single-sign-on-hydra-admin:4445 - publicUrl: https://sso.stackspin.example.org/web/ + + # Public URL of login panel + publicUrl: https://dashboard.stackspin.example.org/web/ databaseUrl: mysql+pymysql://stackspin:stackspin@single-sign-on-database-mariadb/stackspin ## Kubernetes service configuration. For minikube, set this to NodePort, elsewhere use LoadBalancer or ClusterIP