job.yml 1.53 KB
Newer Older
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
apiVersion: batch/v1
kind: Job
metadata:
  name: import-process-delete
  namespace: memobase
  labels:
    app: import-process-delete-app
spec:
  template:
    metadata:
      labels:
        app: import-process-delete-app
        tier: web
    spec:
      containers:
        - name: import-process-administrator-container
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
17
18
19
          volumeMounts:
            - name: media-volume
              mountPath: /data
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
20
21
22
23
24
25
26
27
          args: # Customise to match your needs
            - "--record-set-filter <id>"
            - "--record-filter <id>"
            - "--institution-filter <id>"
            - "--session-filter <id>"
            - "--created-after <datetime>"
            - "--created-before <datetime>"
            - "<your-session-id>"
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
28
29
30
31
32
33
34
35
36
37
          image: cr.gitlab.switch.ch/memoriav/memobase-2020/utilities/import-process-delete:latest
          imagePullPolicy: Always
          env:
            - name: JOB_ID
              value: import-process-delete
            - name: KAFKA_BOOTSTRAP_SERVERS
              value: mb-ka1.memobase.unibas.ch:9092,mb-ka2.memobase.unibas.ch:9092,mb-ka3.memobase.unibas.ch:9092
            - name: CLIENT_ID
              value: import-process-delete
            - name: TOPIC_IN
38
              value: postprocessing-reporting
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
39
            - name: TOPIC_OUT
40
              value: import-process-test-delete
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
41
42
43
            - name: POLL_TIMEOUT
              value: "60000"
      restartPolicy: Never
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
44
45
46
47
      volumes:
        - name: media-volume
          persistentVolumeClaim:
            claimName: media-volume-claim
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
48
  backoffLimit: 1
Sebastian Schüpbach's avatar
Sebastian Schüpbach committed
49