diff --git a/docs/installation/kubernetes.md b/docs/installation/kubernetes.md index b6591d871..26436f0a9 100644 --- a/docs/installation/kubernetes.md +++ b/docs/installation/kubernetes.md @@ -5,12 +5,13 @@ For a mid to high-load installation, Kubernetes is recommended. passbook is inst This installation automatically applies database migrations on startup. After the installation is done, you can use `pbadmin` as username and password. ``` -# Default values for passbook. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. -# passbook version to use. Defaults to latest stable version -# image: -# tag: +################################### +# Values directly affecting passbook +################################### +image: + name: beryju/passbook + name_static: beryju/passbook-static + tag: 0.9.0-stable nameOverride: "" @@ -20,6 +21,7 @@ config: # Enable error reporting error_reporting: enabled: false + environment: customer send_pii: false # Log level used by web and worker # Can be either debug, info, warning, error @@ -32,19 +34,15 @@ config: # bucket: s3-bucket # host: s3-host -ingress: - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" - path: / - hosts: - - passbook.k8s.local - tls: [] - # - secretName: chart-example-tls - # hosts: - # - passbook.k8s.local +################################### +# Values controlling dependencies +################################### -# These settings configure the packaged PostgreSQL and Redis chart. +install: + postgresql: true + redis: true + +# These values influence the bundled postgresql and redis charts, but are also used by passbook to connect postgresql: postgresqlDatabase: passbook @@ -56,4 +54,16 @@ redis: enabled: false # https://stackoverflow.com/a/59189742 disableCommands: [] + +ingress: + annotations: {} + # kubernetes.io/ingress.class: nginx + # kubernetes.io/tls-acme: "true" + path: / + hosts: + - passbook.k8s.local + tls: [] + # - secretName: chart-example-tls + # hosts: + # - passbook.k8s.local ``` diff --git a/helm/Chart.yaml b/helm/Chart.yaml index 44d14fe9a..de0325268 100644 --- a/helm/Chart.yaml +++ b/helm/Chart.yaml @@ -5,9 +5,11 @@ name: passbook version: "0.9.0-stable" icon: https://github.com/BeryJu/passbook/blob/master/passbook/static/static/passbook/logo.svg dependencies: -- name: postgresql - version: 9.3.2 - repository: https://charts.bitnami.com/bitnami -- name: redis - version: 10.7.16 - repository: https://charts.bitnami.com/bitnami + - name: postgresql + version: 9.3.2 + repository: https://charts.bitnami.com/bitnami + condition: install.postgresql + - name: redis + version: 10.7.16 + repository: https://charts.bitnami.com/bitnami + condition: install.redis diff --git a/helm/templates/static-deployment.yaml b/helm/templates/static-deployment.yaml index 2f483e881..f723d219f 100644 --- a/helm/templates/static-deployment.yaml +++ b/helm/templates/static-deployment.yaml @@ -23,7 +23,7 @@ spec: spec: containers: - name: {{ .Chart.Name }}-static - image: "beryju/passbook-static:{{ .Values.image.tag }}" + image: "{{ .Values.image.name_static }}:{{ .Values.image.tag }}" imagePullPolicy: IfNotPresent ports: - name: http diff --git a/helm/templates/web-deployment.yaml b/helm/templates/web-deployment.yaml index 9a36d5c30..06be6d13b 100644 --- a/helm/templates/web-deployment.yaml +++ b/helm/templates/web-deployment.yaml @@ -24,7 +24,7 @@ spec: spec: initContainers: - name: passbook-database-migrations - image: "beryju/passbook:{{ .Values.image.tag }}" + image: "{{ .Values.image.name }}:{{ .Values.image.tag }}" imagePullPolicy: Always args: - ./manage.py @@ -51,7 +51,7 @@ spec: key: postgresql-password containers: - name: {{ .Chart.Name }} - image: "beryju/passbook:{{ .Values.image.tag }}" + image: "{{ .Values.image.name }}:{{ .Values.image.tag }}" imagePullPolicy: Always args: - uwsgi diff --git a/helm/templates/worker-deployment.yaml b/helm/templates/worker-deployment.yaml index 8ff9c7dc5..6be095439 100644 --- a/helm/templates/worker-deployment.yaml +++ b/helm/templates/worker-deployment.yaml @@ -24,7 +24,7 @@ spec: spec: containers: - name: {{ .Chart.Name }} - image: "beryju/passbook:{{ .Values.image.tag }}" + image: "{{ .Values.image.name }}:{{ .Values.image.tag }}" imagePullPolicy: IfNotPresent args: - celery diff --git a/helm/values.yaml b/helm/values.yaml index 87bb5b93b..7444f955e 100644 --- a/helm/values.yaml +++ b/helm/values.yaml @@ -1,7 +1,9 @@ -# Default values for passbook. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. +################################### +# Values directly affecting passbook +################################### image: + name: beryju/passbook + name_static: beryju/passbook-static tag: 0.9.0-stable nameOverride: "" @@ -25,19 +27,15 @@ config: # bucket: s3-bucket # host: s3-host -ingress: - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" - path: / - hosts: - - passbook.k8s.local - tls: [] - # - secretName: chart-example-tls - # hosts: - # - passbook.k8s.local +################################### +# Values controlling dependencies +################################### -# These settings configure the packaged PostgreSQL and Redis chart. +install: + postgresql: true + redis: true + +# These values influence the bundled postgresql and redis charts, but are also used by passbook to connect postgresql: postgresqlDatabase: passbook @@ -49,3 +47,15 @@ redis: enabled: false # https://stackoverflow.com/a/59189742 disableCommands: [] + +ingress: + annotations: {} + # kubernetes.io/ingress.class: nginx + # kubernetes.io/tls-acme: "true" + path: / + hosts: + - passbook.k8s.local + tls: [] + # - secretName: chart-example-tls + # hosts: + # - passbook.k8s.local