apiVersion: batch/v1 kind: Job metadata: name: indico-db-init namespace: {{ .namespace }} labels: component: db-init spec: template: metadata: labels: component: db-init spec: restartPolicy: OnFailure securityContext: runAsNonRoot: true runAsUser: 999 runAsGroup: 999 seccompProfile: type: RuntimeDefault containers: - name: db-init image: postgres:17 securityContext: allowPrivilegeEscalation: false capabilities: drop: [ALL] readOnlyRootFilesystem: false command: ["/bin/bash", "-c"] args: - | PGPASSWORD=${POSTGRES_ADMIN_PASSWORD} psql -h ${DB_HOST} -U postgres <