This repository contains a Bodywork project that demonstrates how to run a batch workload (or job) on Kubernetes, with Bodywork. For information on this demo, take a look here. To run this project, follow the steps below. If you are new to Kubernetes, then take a look at our Kubernetes Quickstart Guide.
Bodywork is distributed as a Python package that can be installed using Pip,
$ pip install bodywork
To execute the workload defined in this repository run,
$ bodywork create deployment https://github.com/bodywork-ml/bodywork-batch-job-project
Logs will be streamed to your terminal until the job has been successfully completed.
If you're happy with the result, you can schedule the workflow-controller to operate remotely on the cluster on a pre-defined schedule. For example, to setup the the workflow to run every hour, use the following command,
$ bodywork create cronjob https://github.com/bodywork-ml/bodywork-batch-job-project \
--name=hourly-job \
--schedule="0 * * * *"
Each scheduled workflow will attempt to re-run the batch-job, as defined by the state of this repository's master
branch at the time of execution.
This repository is a GitHub template repository that can be automatically copied into your own GitHub account by clicking the Use this template
button above.
After you've cloned the template project, use official Bodywork documentation to help modify the project to meet your own requirements.