Last active
August 27, 2020 17:18
-
-
Save dontlaugh/e2dcc4c933d9d69678e7c795434546eb to your computer and use it in GitHub Desktop.
Data auditing cron job (update-checker)
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
apiVersion: batch/v1beta1 | |
kind: CronJob | |
metadata: | |
name: update-checker | |
namespace: apis | |
annotations: | |
fluxcd.io/automated: "true" | |
fluxcd.io/tag.update-checker: glob:sha-* | |
spec: | |
# Every 6 hours | |
schedule: "0 */6 * * *" | |
jobTemplate: | |
spec: | |
template: | |
spec: | |
containers: | |
- name: update-checker | |
image: novelcovid/novelcovid-api:sha-cd9021e | |
command: | |
- npm | |
- run | |
- updateCheck | |
imagePullPolicy: Always | |
env: | |
- name: WEBHOOK_TOKEN | |
valueFrom: | |
secretKeyRef: | |
name: discord-token | |
key: WEBHOOK_TOKEN | |
restartPolicy: Never | |
imagePullSecrets: | |
- name: docker.greymatter.io |
We can change the schedule if need be
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What is the env var the job expects? Can we put this job into an NPM run script?