apiVersion: batch/v1
kind: Job
metadata:
  name: tendr-api-schema
  labels:
    app: tendr-api
spec:
  ttlSecondsAfterFinished: 0
  template:
    metadata:
      labels:
        app: tendr-api
    spec:
      restartPolicy: Never
      imagePullSecrets:
      - name: regcred
      containers:
        - name: goose
          image: ghcr.io/coding-couch/tendr-goose:v0.0.9
          args:
            - "goose"
            - "-dir"
            - "./cmd/goose/migrations"
            - "postgres://"
            - "up"
          envFrom:
            - secretRef:
                name: tendr-api-db-credentials