-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: init cron job for copilot test
- Loading branch information
1 parent
a08d728
commit 31ce694
Showing
3 changed files
with
131 additions
and
16 deletions.
There are no files selected for viewing
35 changes: 35 additions & 0 deletions
35
.github/helm/affine/charts/graphql/templates/copilot-test.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
apiVersion: batch/v1 | ||
kind: CronJob | ||
metadata: | ||
name: {{ include "graphql.fullname" . }}-copilot-test | ||
labels: | ||
{{- include "graphql.labels" . | nindent 4 }} | ||
annotations: | ||
"helm.sh/hook": post-install,post-upgrade | ||
"helm.sh/hook-weight": "1" | ||
"helm.sh/hook-delete-policy": before-hook-creation | ||
spec: | ||
schedule: "0 8 * * *" | ||
jobTemplate: | ||
spec: | ||
template: | ||
spec: | ||
serviceAccountName: {{ include "graphql.serviceAccountName" . }} | ||
containers: | ||
- name: {{ .Chart.Name }} | ||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" | ||
command: ["yarn", "test:copilot:e2e"] | ||
env: | ||
- name: COPILOT_E2E_ENDPOINT | ||
value: "{{ include "graphql.fullname" . }}.{{ .Release.Namespace }}.svc.cluster.local" | ||
- name: DATABASE_PASSWORD | ||
valueFrom: | ||
secretKeyRef: | ||
name: pg-postgresql | ||
key: postgres-password | ||
resources: | ||
requests: | ||
cpu: '100m' | ||
memory: '200Mi' | ||
restartPolicy: Never | ||
backoffLimit: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters