Skip to content

Commit

Permalink
reporting 0.3.5, cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
wozniakpl committed Sep 2, 2024
1 parent 030290d commit b40ff91
Show file tree
Hide file tree
Showing 13 changed files with 45 additions and 81 deletions.
2 changes: 1 addition & 1 deletion charts/core/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ spec:
{{- if .Values.flower.enabled }}
- path: /flower/
pathType: Prefix
backend:
backend:
service:
name: {{ include "core.fullname" . }}-celery-flower
port:
Expand Down
2 changes: 1 addition & 1 deletion charts/reporting/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ 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.3.4
version: 0.3.5

# 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
Expand Down
2 changes: 1 addition & 1 deletion charts/reporting/templates/deployment-backend.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,5 +54,5 @@ spec:
driver: secrets-store.csi.k8s.io
readOnly: true
volumeAttributes:
secretProviderClass: {{ .Values.keyvault.secretProviderName }}
secretProviderClass: {{ include "reporting.fullname" . }}-secret-provider
{{- end }}
2 changes: 1 addition & 1 deletion charts/reporting/templates/deployment-celery-beat.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,5 @@ spec:
driver: secrets-store.csi.k8s.io
readOnly: true
volumeAttributes:
secretProviderClass: {{ .Values.keyvault.secretProviderName }}
secretProviderClass: {{ include "reporting.fullname" . }}-secret-provider
{{- end }}
2 changes: 1 addition & 1 deletion charts/reporting/templates/deployment-celery-worker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,5 @@ spec:
driver: secrets-store.csi.k8s.io
readOnly: true
volumeAttributes:
secretProviderClass: {{ .Values.keyvault.secretProviderName }}
secretProviderClass: {{ include "reporting.fullname" . }}-secret-provider
{{- end }}
63 changes: 18 additions & 45 deletions charts/reporting/templates/ingress.yaml
Original file line number Diff line number Diff line change
@@ -1,61 +1,34 @@
{{- if .Values.ingress.enabled -}}
{{- $fullName := include "reporting.fullname" . -}}
{{- $svcPort := .Values.backend.service.port -}}
{{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }}
{{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }}
{{- $_ := set .Values.ingress.annotations "kubernetes.io/ingress.class" .Values.ingress.className}}
{{- end }}
{{- end }}
{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion -}}
apiVersion: networking.k8s.io/v1
{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}}
apiVersion: networking.k8s.io/v1beta1
{{- else -}}
apiVersion: extensions/v1beta1
{{- end }}
kind: Ingress
metadata:
name: {{ $fullName }}
name: {{ include "reporting.fullname" . }}-ingress
labels:
{{- include "reporting.labels" . | nindent 4 }}
{{- with .Values.ingress.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if and .Values.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }}
ingressClassName: {{ .Values.ingress.className }}
{{- end }}
{{- if .Values.ingress.tls }}
tls:
{{- range .Values.ingress.tls }}
- hosts:
{{- range .hosts }}
- {{ . | quote }}
{{- end }}
secretName: {{ .secretName }}
{{- end }}
{{- end }}
rules:
{{- range .Values.ingress.hosts }}
- host: {{ .host | quote }}
- host: {{ .Values.ingress.host }}
http:
paths:
{{- range .paths }}
- path: {{ .path }}
{{- if and .pathType (semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion) }}
pathType: {{ .pathType }}
{{- end }}
backend:
{{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }}
service:
name: {{ $fullName }}
port:
number: {{ $svcPort }}
{{- else }}
serviceName: {{ $fullName }}
servicePort: {{ $svcPort }}
{{- end }}
{{- end }}
{{- end }}
{{- if .Values.flower.enabled }}
- path: /flower/
pathType: Prefix
backend:
service:
name: {{ include "reporting.fullname" . }}-celery-flower
port:
number: {{ .Values.flower.service.port }}
{{- end }}
- path: /
pathType: Prefix
backend:
service:
name: {{ include "reporting.fullname" . }}-backend
port:
number: {{ .Values.backend.service.port }}
{{- end }}
2 changes: 1 addition & 1 deletion charts/reporting/templates/job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,6 @@ spec:
driver: secrets-store.csi.k8s.io
readOnly: true
volumeAttributes:
secretProviderClass: {{ .Values.keyvault.secretProviderName }}
secretProviderClass: {{ include "reporting.fullname" . }}-secret-provider
{{- end }}
backoffLimit: 3
2 changes: 1 addition & 1 deletion charts/reporting/templates/keyvault.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: secrets-store.csi.x-k8s.io/v1
kind: SecretProviderClass
metadata:
name: {{ .Values.keyvault.secretProviderName }}
name: {{ include "reporting.fullname" . }}-secret-provider
spec:
provider: azure
parameters:
Expand Down
15 changes: 0 additions & 15 deletions charts/reporting/templates/tests/test-connection.yaml

This file was deleted.

11 changes: 9 additions & 2 deletions charts/reporting/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.

replicaCount: 1

image:
repository: unicef/hope-support-images
pullPolicy: IfNotPresent
Expand Down Expand Up @@ -105,3 +103,12 @@ backend:
type: ClusterIP
port: 8000

celery:
replicaCount: 1

keyvault:
enabled: false
mountPath: /mnt/secrets

flower:
enabled: false
Binary file removed docs/hope-country-report-0.3.2.tgz
Binary file not shown.
23 changes: 11 additions & 12 deletions docs/index.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ entries:
core:
- apiVersion: v2
appVersion: core-2.10.1
created: "2024-09-02T13:21:28.256247+02:00"
created: "2024-09-02T13:38:17.0188+02:00"
dependencies:
- condition: postgresql.enabled
name: postgresql
Expand All @@ -24,21 +24,20 @@ entries:
urls:
- https://unicef.github.io/hope-helm-charts/core-0.1.3.tgz
version: 0.1.3
hope-country-report:
reporting:
- apiVersion: v2
appVersion: country-report-cd55e1362cc62508ef33e2b900930c1fb42aa2f9
created: "2024-09-02T13:21:28.256718+02:00"
created: "2024-09-02T13:38:17.020307+02:00"
description: A Helm chart for Kubernetes
digest: ffb6d9531cd0a54aed7a421c4a97c685e09dc372b57dd06eb1af32a3736e6314
name: hope-country-report
digest: 77127f0ada1776aa929db12510659ab43bfcbd6b7e14d083a8a18a73b9674b81
name: reporting
type: application
urls:
- https://unicef.github.io/hope-helm-charts/hope-country-report-0.3.2.tgz
version: 0.3.2
reporting:
- https://unicef.github.io/hope-helm-charts/reporting-0.3.5.tgz
version: 0.3.5
- apiVersion: v2
appVersion: country-report-cd55e1362cc62508ef33e2b900930c1fb42aa2f9
created: "2024-09-02T13:21:28.258479+02:00"
created: "2024-09-02T13:38:17.020067+02:00"
description: A Helm chart for Kubernetes
digest: c9803cb5241c6818973df3fab76a5e698c6a285a768e6bfa7250541cc1090924
name: reporting
Expand All @@ -48,7 +47,7 @@ entries:
version: 0.3.4
- apiVersion: v2
appVersion: country-report-cd55e1362cc62508ef33e2b900930c1fb42aa2f9
created: "2024-09-02T13:21:28.258213+02:00"
created: "2024-09-02T13:38:17.01965+02:00"
description: A Helm chart for Kubernetes
digest: 7373111b2f23fe71681a318b47b3b13f9f756fbb132b0bd4e14ccb65fd669fa2
name: reporting
Expand All @@ -58,12 +57,12 @@ entries:
version: 0.3.3
- apiVersion: v2
appVersion: country-report-cd55e1362cc62508ef33e2b900930c1fb42aa2f9
created: "2024-09-02T13:21:28.257824+02:00"
created: "2024-09-02T13:38:17.019235+02:00"
description: A Helm chart for Kubernetes
digest: b292b4c67a960951f5dd46f27d6f92fa66be8625a51abcd494247f2bbc50983e
name: reporting
type: application
urls:
- https://unicef.github.io/hope-helm-charts/reporting-0.3.2.tgz
version: 0.3.2
generated: "2024-09-02T13:21:28.242709+02:00"
generated: "2024-09-02T13:38:17.005568+02:00"
Binary file added docs/reporting-0.3.5.tgz
Binary file not shown.

0 comments on commit b40ff91

Please sign in to comment.