improwised-charts/experimental/n8n-helm/templates/tests/test-n8n.yaml

21 lines
608 B
YAML

{{- if .Values.testFramework.enabled }}
apiVersion: v1
kind: Pod
metadata:
name: n8n-working-test
annotations:
"helm.sh/hook": test-success
spec:
containers:
- name: n8n-working-test
image: "alpine"
imagePullPolicy: {{ .Values.image.pullPolicy }}
env:
- name: N8N_HOST
value: {{ template "n8n-helm.fullname" . }}-service.default.svc.cluster.local:{{ .Values.service.port }}
command:
- /bin/sh
- -ec
- sleep 10; apk update; apk add curl; curl -m 10 -s -o /dev/null -I -w "%{http_code}" $N8N_HOST
restartPolicy: Never
{{- end }}