-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathend-story.yaml
31 lines (31 loc) · 1.23 KB
/
end-story.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
apiVersion: batch/v1
kind: Job
metadata:
name: {STORY_ID}-end-story
spec:
backoffLimit: 0
ttlSecondsAfterFinished: 0
template:
spec:
containers:
- name: end-story
image: us.gcr.io/$ARTEFACTS_PROJECT_NAME/video-composer
command: ["bash", "-c",
"echo end-story `date` >> /data/events.log && \
gsutil copy /data/normalized-story.mp4 gs://${GENERATED_BUCKET_NAME}/{STORY_ID}/ && \
gsutil copy /data/dynamic-overlay.mp4 gs://${GENERATED_BUCKET_NAME}/{STORY_ID}/ && \
gsutil copy /data/composed-story.mp4 gs://${GENERATED_BUCKET_NAME}/{STORY_ID}/ && \
gsutil copy /data/story.yaml gs://${GENERATED_BUCKET_NAME}/{STORY_ID}/ && \
rm -rf /data/* && \
gcloud pubsub topics publish completed-end-story \
--message \"{STORY_ID}\" && \
echo end-story `date` >> /data/events.log"]
volumeMounts:
- name: data
mountPath: /data
subPath: {STORY_ID}
restartPolicy: Never
volumes:
- name: data
hostPath:
path: /mnt/disks/ssd0