A simple image based on python:3.7-alpine to execute Python scripts inside a directory. By default the entrypoint.sh script will execute all .py files in the directory /opt/scripts/
There are two examples provided that both make use of Kubernetes CronJobs - See below:
-
Create the
ConfigMapandCronJobfrom a single YAML file:kubectl apply -f examples/cronjob-aio.yaml
-
Create the
ConfigMapfrom a folder:kubectl create configmap example-scripts-dir --from-file=examples/exampleScripts -
Create the
CronJobkubectl apply -f examples/cronjob-standalone.yaml