Skip to content

Commit

Permalink
Merge pull request #15 from diggerhq/fix/default-values-that-broke-1.5
Browse files Browse the repository at this point in the history
fix the default values that broke 1.5
  • Loading branch information
motatoes committed Sep 16, 2024
2 parents 619f07f + 68e40ad commit ae7f530
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 17 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ To configure the Digger backend deployment with the Helm chart, you'll need to s
- `digger.annotations`: Add the needed annotations based on your ingress controller configuration.
- `digger.ingress.host`: The hostname to use for the Ingress resource (e.g., `digger-backend.test`).
- `digger.ingress.path`: The path for the Ingress resource (e.g., `/`).
- `digger.ingress.className`: the classname to use for ingress (only considered for kuberetes >= 1.18)
- `digger.ingress.tls.secretName`: The name of the TLS secret to use for Ingress encryption (e.g., `digger-backend-tls`).

- `digger.secret.*`: Various secrets needed for the application, such as `HTTP_BASIC_AUTH_PASSWORD` and `BEARER_AUTH_TOKEN`. You can provide them directly or reference an existing Kubernetes secret by setting `useExistingSecret` to `true` and specifying `existingSecretName`.
Expand Down
4 changes: 2 additions & 2 deletions charts/digger-backend/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.1.5
version: 0.1.6

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "v0.4.2"
appVersion: "v0.6.42"
14 changes: 7 additions & 7 deletions charts/digger-backend/templates/backend-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,25 +35,25 @@ spec:
secretKeyRef:
name: {{ .Values.postgres.secret.existingSecretName }}
key: postgres-password
{{- else if .Values.digger.postgres.existingSecretName }}
valueFrom:
secretKeyRef:
name: {{ .Values.digger.postgres.existingSecretName }}
key: {{ .Values.digger.postgres.existingSecretKey }}
{{- else }}
valueFrom:
secretKeyRef:
name: {{ include "digger-backend.fullname" . }}-postgres-secret
key: postgres-password
{{- end }}
{{- if and .Values.digger.postgres.existingSecretName (not .Values.postgres.enabled) }}
valueFrom:
secretKeyRef:
name: {{ .Values.digger.postgres.existingSecretName }}
key: {{ .Values.digger.postgres.existingSecretKey }}
{{- end }}
- name: HTTP_BASIC_AUTH
value: "1"
- name: DATABASE_URL
{{- if .Values.postgres.enabled }}
value: "postgres://postgres:$(POSTGRES_PASSWORD)@{{ include "digger-backend.fullname" . }}-postgres:5432/postgres?sslmode=disable"
{{- else }}
value: "postgres://{{ .Values.digger.postgres.user }}:$(POSTGRES_PASSWORD)@{{ .Values.digger.postgres.host }}:{{ .Values.digger.postgres.port }}/{{ .Values.digger.postgres.database }}?sslmode=disable"
{{- $pg := .Values.digger.postgres }}
value: "postgres://{{ $pg.user }}:$(POSTGRES_PASSWORD)@{{ $pg.host }}:{{ $pg.port }}/{{ $pg.database }}?sslmode=disable"
{{- end }}
- name: ALLOW_DIRTY
value: "{{ .Values.digger.postgres.allow_dirty }}"
14 changes: 6 additions & 8 deletions charts/digger-backend/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ digger:
# tag: digger backend image tag
image:
repository: registry.digger.dev/diggerhq/digger_backend
tag: "v0.4.9"
tag: "v0.6.42"

# livenessProbe and startupProbe settings
# https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
Expand Down Expand Up @@ -44,12 +44,12 @@ digger:
# secretName: name of k8s secret for tls certs (default: "digger-backend-tls")
ingress:
enabled: true
className: "test"
className: ""
annotations:
{}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: 'true'
host: "example.org"
host: ""
path: /
tls:
secretName: "digger-backend-tls"
Expand Down Expand Up @@ -85,10 +85,8 @@ digger:
# configure this section if you want to use an external postgres database

postgres:
# if the DB connection string is already in a secret
# DB connection string should be in a key names DATABASE_URL
# compatible with https://github.com/kloeckner-i/db-operator, for example
existingSecretName: "new-pg-creds"
# specify the secret name and key to pull the existing postgres database password from
existingSecretName: ""
existingSecretKey: "postgres-password"

# to define connection details in chart:
Expand All @@ -102,7 +100,7 @@ digger:
# configure this section if you want to deploy a postgres db
# WARNING: use only for test purposes, no persistency has been configured
postgres:
enabled: true
enabled: false
image: postgres
tag: "14"
resources:
Expand Down

0 comments on commit ae7f530

Please sign in to comment.