Files
photos/deploy/chart/templates/_helpers.tpl
T
nilsandClaude 16d2a56a78
ci / docker (push) Successful in 13s
Initial release: self-hosted client photo gallery
Rust (axum + sqlx) API and worker sharing a Postgres-backed job queue
(SKIP LOCKED, heartbeat, reaper, typed statuses), S3 storage with derived
keys and a fully private bucket, OIDC photographer login with per-request
allowlist checks, client share links with argon2 passwords and lockout,
cookie-based image authorization with sliding expiry, hand-rolled
spec-compliant streaming ZIP downloads with exact Content-Length,
React + Vite gallery frontend, single Docker image, Helm chart for
external S3 + Postgres, and Gitea CI.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-17 13:12:42 +02:00

43 lines
1.2 KiB
Smarty

{{- define "photos.fullname" -}}
{{- if contains "photos" .Release.Name -}}
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
{{- else -}}
{{- printf "%s-photos" .Release.Name | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{- end -}}
{{- define "photos.labels" -}}
app.kubernetes.io/name: photos
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end -}}
{{- define "photos.secretName" -}}
{{- if .Values.secrets.existingSecret -}}
{{- .Values.secrets.existingSecret -}}
{{- else -}}
{{- include "photos.fullname" . -}}
{{- end -}}
{{- end -}}
{{- define "photos.env" -}}
- name: PUBLIC_URL
value: {{ .Values.publicUrl | quote }}
- name: S3_BUCKET
value: {{ .Values.config.s3.bucket | quote }}
- name: S3_REGION
value: {{ .Values.config.s3.region | quote }}
{{- if .Values.config.s3.endpoint }}
- name: S3_ENDPOINT
value: {{ .Values.config.s3.endpoint | quote }}
{{- end }}
- name: S3_FORCE_PATH_STYLE
value: {{ .Values.config.s3.forcePathStyle | quote }}
- name: OIDC_ISSUER
value: {{ .Values.config.oidcIssuer | quote }}
- name: ALLOWED_EMAILS
value: {{ .Values.config.allowedEmails | quote }}
- name: RUST_LOG
value: {{ .Values.config.logLevel | quote }}
{{- end -}}