-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Better support for CI systems that provide many env vars #1294
Comments
@poy is working on migrating https://github.com/google/kf from Knative Build to Tekton (🎉 ) and ran into this speedbump. As a workaround they're going to create a
Thought it might be worth mentioning as a (kinda cruddy) workaround until we come up with something better. |
Rotten issues close after 30d of inactivity. /close Send feedback to tektoncd/plumbing. |
Issues go stale after 90d of inactivity. /lifecycle stale Send feedback to tektoncd/plumbing. |
@tekton-robot: Closing this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/remove-lifecycle rotten |
@vdemeester: Reopened this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
I think people who want to use Tekton should make dependencies explicit by using parameters. Environment variables are globals and we stopped using globals in code; I say it shouldn't be encouraged. I am writing a Task to parse each Prow environment variable and put each into a result. (It'll get it from Prow via an encoded string passed as a single param). |
Issues go stale after 90d of inactivity. /lifecycle stale Send feedback to tektoncd/plumbing. |
Stale issues rot after 30d of inactivity. /lifecycle rotten Send feedback to tektoncd/plumbing. |
Rotten issues close after 30d of inactivity. /close Send feedback to tektoncd/plumbing. |
@tekton-robot: Closing this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Expected Behavior
Many CI systems expect to pass a plethora of environment variables to executing logic (in our case, to the executing Step containers).
For example, these are environment varaibles that Jenkins X provides, and these are environment variables that Prow provides. Each has ~12-15+ env vars to provide.
It should be possible for CI systems that want to integrate with Tekton to:
But at the same time we need to uphold Tekton principles, specifically avoiding implied coupling between Step containers and the CI system.
For example, say the CI system provides an environment variable
PROW_JOB_ID
and containergcr.io/someregistry/write-results
uses the environment variablePROW_JOB_ID
. It should be clear to anyone using a step that usesgcr.io/someregistry/write-results
that the environment variablePROW_JOB_ID
must be provided.Actual Behavior
Currently all environment variables that are provided to a step must be listed explicitly. Providing a set of ~15 environment variable automatically to a Pipeline + Tasks could easily end up looking like:
Both of these lead to brittle Pipelines and Tasks that can't be reused, and need to be updated to stay in sync with the CI system.
Additional Info
EnvVarPipelineResource
which could maybe hold bundle of env vars, and there would be a way to easily link those Resources to executing images (maybe @imjasonh could provide more detail here)The text was updated successfully, but these errors were encountered: