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

Fix Pipeline error with ClusterTasks #1003

Merged

Conversation

vdemeester
Copy link
Member

Changes

It is possible to use ClusterTask in a Pipeline, for that you
specify that the Task you want to use is of type
ClusterTask (default being Task). But, before this change, the
PipelineRun using this Pipeline would fail as the Kind
information is not passed from the PipelineTask.TaskRef to the
actual TaskRun.

This fixes that by passing the Kind of a TaskRef when resolving
the Task/TaskRun in the PipelineRun reconcilier.

A yaml test is added as a regression test.

Fixes #1001 — thanks for the report @steveodonovan

/cc @bobcatfish

Signed-off-by: Vincent Demeester [email protected]

Submitter Checklist

These are the criteria that every PR should meet, please check them off as you
review them:

See the contribution guide
for more details.

Release Notes

Fix ClusterTask usage in a PipelineRun, would previously fail.

It is possible to use `ClusterTask` in a Pipeline, for that you
specify that the `Task` you want to use is of type
`ClusterTask` (default being `Task`). But, before this change, the
`PipelineRun` using this `Pipeline` would fail as the `Kind`
information is not passed from the `PipelineTask.TaskRef` to the
actual `TaskRun`.

This fixes that by passing the `Kind` of a `TaskRef` when resolving
the `Task`/`TaskRun` in the `PipelineRun` reconcilier.

A yaml test is added as a regression test.

Signed-off-by: Vincent Demeester <[email protected]>
@tekton-robot tekton-robot requested a review from bobcatfish June 24, 2019 09:58
@tekton-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: vdemeester

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@googlebot googlebot added the cla: yes Trying to make the CLA bot happy with ppl from different companies work on one commit label Jun 24, 2019
@tekton-robot tekton-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jun 24, 2019
@vdemeester
Copy link
Member Author

/test pull-tekton-pipeline-integration-tests

@dlorenc
Copy link
Contributor

dlorenc commented Jun 25, 2019

/test pull-tekton-pipeline-go-coverage

1 similar comment
@dlorenc
Copy link
Contributor

dlorenc commented Jun 25, 2019

/test pull-tekton-pipeline-go-coverage

@dlorenc
Copy link
Contributor

dlorenc commented Jun 26, 2019

/lgtm

@tekton-robot tekton-robot added the lgtm Indicates that a PR is ready to be merged. label Jun 26, 2019
@tekton-robot tekton-robot merged commit cf2ecd5 into tektoncd:master Jun 26, 2019
@vdemeester vdemeester deleted the 1001-pipeline-with-clustertask branch June 26, 2019 05:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cla: yes Trying to make the CLA bot happy with ppl from different companies work on one commit lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cluster Tasks Cannot be Run from a pipelineRun
4 participants