-
Notifications
You must be signed in to change notification settings - Fork 123
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
Generate Tekton Pipeline with Tasks #17
Conversation
/assign @animeshsingh |
Hi @ckadner, do you know what version of tekton you tested this on? Probably we may want to add that into the readme on the versions of tekton it supported. |
@Tomcli -- I am using |
Sure, can we put the tested version in the README. The reason I bring it up because Tekton just have their new beta api release in 0.11 and our current yaml are based on their alpha api. |
Thanks @Tomcli for raising the topic of tested/supported versions. I started a section in the |
Replace Steps with Tasks to allow parallel task execution. Use 'runAfter' to support sequential task execution.
Just on release point, Tekton beta with 0.11 onwards will guarantee some sort of API stability, and hence we should migrate to them as and when schedule permits |
Hi Christian, how do you pass parameter between each task? I was trying to use kfp's parallel join example and get the following errors generated pipeline.yaml
errors
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks @ckadner for this. Looks great!
apart from ContainerOps and ResourceOps, there are others operation for Volume, Secret etc...part of the plan I think coming in future?
} | ||
} | ||
|
||
elif isinstance(op, dsl.ResourceOp): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what's the ResourceOp significance in DSL?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ResourceOp
represents a pipeline task (op) which lets you directly manipulate Kubernetes resources (create
,get
,apply
, …)
... KFP has an example using ResourceOp
for PVC creation
import tarfile | ||
import yaml | ||
import zipfile | ||
from typing import Callable, Set, List, Text, Dict, Tuple, Any, Union, Optional |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we import the whole thing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, it's a long line of an import statement, but this is the recommended Python practice (https://www.python.org/dev/peps/pep-0008/#imports) -- to make imports as narrow and explicit as possible. Wild-card imports like from typing import *
are strongly discouraged.
And since this was copied down from the KFP compiler I was trying to keep changes to a minimum to make it easier to trace actual code changes in the future.
Hi @Tomcli passing parameters between |
@animeshsingh -- yes, we should list and prioritize next steps. I started this umbrella issue Compiler work items #18 |
added to umbrella issue Compiler work items #18 |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: animeshsingh The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
thanks @animeshsingh and @Tomcli |
Replace Steps with Tasks to allow parallel task execution. Use 'runAfter' to support sequential task execution.
Replace
steps
withtasks
to allow parallel task execution.Use
runAfter
to support sequential task execution.The compile now generates multiple documents in one YAML file, one per
Task
and one for thePipeline
.This change is