Skip to content

Kubernetes controller for running jobs specified in a graph definition

License

Notifications You must be signed in to change notification settings

Carlos-Descalzi/jobgraphs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jobgraphs

Kubernetes controller for running jobs specified in a directed acyclic graph definition. Jobs represent nodes in the graph, when the resource is created, the controller will start running jobs according to the graph definition. The field 'jobFailureCondition' in job graph has two possible values, fail or continue, this tells the controller what to do once a job/node fails. The field 'graph' declares the graph definition as an array of edges, defined by source and target job names.

Example jobgraph:

apiVersion: ced.io/v1alpha1
kind: JobGraph
metadata:
  name: test-graph
spec:
  jobFailureCondition: fail
  graph:
    edges:
      - source: job1
        target: job2
  jobTemplates:
    - metadata:
        name: job1
      spec:
        template:
          spec:
            containers:
              - image: ubuntu:20.04
                command: ["echo","hello world"]
            restartPolicy: Never
    - metadata:
        name: job2
      spec:
        template:
          spec:
            containers:
              - image: ubuntu:20.04
                command: ["echo","hello world"]
            restartPolicy: Never

Install

kubectl apply -f https://github.com/Carlos-Descalzi/jobgraphs/blob/main/deploy/crd.yaml
kubectl apply -f https://github.com/Carlos-Descalzi/jobgraphs/blob/main/deploy/rbac.yaml
kubectl apply -f https://github.com/Carlos-Descalzi/jobgraphs/blob/main/deploy/deploy.yaml

About

Kubernetes controller for running jobs specified in a graph definition

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published