Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Workflows should be schedulable like cronjob #29

Open
sdminonne opened this issue Oct 26, 2017 · 11 comments
Open

Workflows should be schedulable like cronjob #29

sdminonne opened this issue Oct 26, 2017 · 11 comments
Assignees

Comments

@sdminonne
Copy link
Contributor

Long story short. One should be able to schedule a workflow like kube cronjob.

@sdminonne sdminonne self-assigned this Nov 23, 2017
@sdminonne
Copy link
Contributor Author

Assigning to me since I'm writing the proposal for this.

@davidc-donorschoose
Copy link
Contributor

I see that a "cron workflow controller: new code" commit went in last month (on December 7, 2018). I don't see any examples in the commit.

We are definitely interested in using this feature. We did a quick merge from your repo into our fork just to try it out. We can build and install the upgraded workflow-controller and even create a CronWorkflow resource (I determined the correct yaml by reading your go source code). The job doesn't appear to run as scheduled - which is completely understandable since you haven't closed this case yet.

We could probably test something for you on AWS EKS if you want.

@sdminonne
Copy link
Contributor Author

@davidc-donorschoose, my understanding is that the cron-workflow though quite green code should work. Many apologizes if this is not the case.
Do you have the manifest file of your cron-workflow? Is it possible for you (or someone of your group) create a small testcase and put it in a gist?
It would help a lot.
Thanks again for testing it.

This was referenced Jan 8, 2019
@sdminonne
Copy link
Contributor Author

We need to create examples in the doc for CronWorkflow and DaemonSetJob

@davidc-donorschoose
Copy link
Contributor

Apologies for the delay. I realized that we tested with a manifest that left out a couple nested yaml tags under the "workflowTemplate". We'll fix this and re-test, which I'm pretty sure will work. Then I'll get you a gist with our yaml that you could consider as a example.

@davidc-donorschoose
Copy link
Contributor

My CronWorkflow didn't run as expected. I created it with the manifest in this gist (https://gist.github.com/davidc-donorschoose/79bb22c203000d4ecea702618923e709). I used UTC for the Schedule set 5 minutes in the future when I ran the kubectl create --namespace=qa -f /tmp/cwfl.yaml command into my EKS cluster. I can see that it created with kubectl describe cwfl/qa-nightly-batch --namespace=qa.

However, it didn't run. I don't see any Workflow, Jobs, or Pods running.

BTW, to see Workflow resources, I have to use the fully scoped custom resource type kubectl get workflow.workflow.k8s.io --namespace=qa, where as I can see my CronWorkflow with the fully scoped type cronworkflow.workflow.k8s.io, but also with cronworkflows, cronworkflow and cwfl.

@sdminonne
Copy link
Contributor Author

@davidc-donorschoose thank for the use case. Going to have a look and if you agree adding something very similar to our e2e test.

@davidc-donorschoose
Copy link
Contributor

Of course, you may use the CronWorkflow manifest in that gist for any purpose. Please let me know if you find something wrong in my yaml code or if you do get something similar to work.

Also, please reach out if you think I can help with AWS EKS testing in some way. I suppose it is possible that EKS has some custom resource incompatibility with your CronWorkflow implementation (although we can create an ordinary Workflow and that does run).

@sdminonne
Copy link
Contributor Author

@davidc-donorschoose thanks.
All the code we've in this repo is tested with 1.9 (if I'm not wrong) but it should work with 1.7.
It uses very basics CRDs features. In the next weeks (hopefully not months) we're going to add more features that will request more advanced CRDs features (OpenAPI validation, subresources and webhooks). Obviously we'll branch preserving 1.9 version in case someone wants to keep some old cluster.

@davidc-donorschoose
Copy link
Contributor

EKS is currently on K8s-v1.10.11

@clamoriniere1A
Copy link
Contributor

Hi @davidc-donorschoose
#89 explains how to fix your CronWorkflow definition.
Regards,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants