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

Make Pipeline task name available in Task/ClusterTask #2294

Closed
dinup24 opened this issue Mar 26, 2020 · 5 comments
Closed

Make Pipeline task name available in Task/ClusterTask #2294

dinup24 opened this issue Mar 26, 2020 · 5 comments
Labels
kind/feature Categorizes issue or PR as related to a new feature. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.

Comments

@dinup24
Copy link

dinup24 commented Mar 26, 2020

The pipeline task name set in the pipeline definition should be made available in the task as internal param or env variable (or in some other way) during execution. The steps/sidecar in the task should be able to use the pipeline task name which could be useful logging/tracing/debugging purposes.

tasks:
  - name: build-the-image
    taskRef:
      name: build-push

In the above example pipeline task name is build-the-image, but it invokes the task build-push. If certain contextual info such as the pipeline task name, pipeline name etc is made available in the task build-push , this will be helpful in understanding the context in which this task was executed (in our case, the same task is executed multiple times in a pipeline to perform same activities for different set of artifacts).

For eg. build-push task will be used to push ui-app image as well api-server image.

@ghost ghost added the kind/feature Categorizes issue or PR as related to a new feature. label Mar 26, 2020
@tekton-robot
Copy link
Collaborator

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close.

/lifecycle rotten

Send feedback to tektoncd/plumbing.

@tekton-robot
Copy link
Collaborator

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

/close

Send feedback to tektoncd/plumbing.

@tekton-robot
Copy link
Collaborator

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close.

/lifecycle stale

Send feedback to tektoncd/plumbing.

@tekton-robot tekton-robot added the lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. label Aug 13, 2020
@tekton-robot
Copy link
Collaborator

@tekton-robot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

/close

Send feedback to tektoncd/plumbing.

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.

@tekton-robot tekton-robot removed the lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. label Aug 13, 2020
@tekton-robot tekton-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Aug 13, 2020
@bobcatfish
Copy link
Collaborator

This may have been somewhat solved by #1522 (thanks @R2wenD2 !)

You can now access variables like the pipelinerun name and the pipelinename in the pipeline - to make these available to a Task/ClusterTask it could declare them as params.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.
Projects
None yet
Development

No branches or pull requests

3 participants