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

Doc about migrating from v1beta1 to v1 #5415

Merged
merged 1 commit into from
Sep 6, 2022

Conversation

JeromeJu
Copy link
Member

@JeromeJu JeromeJu commented Sep 1, 2022

Changes

This commit introduces a doc describing how to migrate from v1beta1 to v1. It details changes of fields as well as deprecations.

Preview: Doc link

Fixes: #5330
/kind documentation

Submitter Checklist

As the author of this PR, please check off the items in this checklist:

  • Has Docs included if any changes are user facing
  • [n/a] Has Tests included if any functionality added or changed
  • Follows the commit message standard
  • Meets the Tekton contributor standards (including
    functionality, content, code)
  • Has a kind label. You can add one by adding a comment on this PR that contains /kind <type>. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tep
  • Release notes block below has been updated with any user facing changes (API changes, bug fixes, changes requiring upgrade notices or deprecation warnings)
  • Release notes contains the string "action required" if the change requires additional action from users switching to the new release

Release Notes

The document has been added that describes the changes needed when migrating from v1beta1 to v1.

@tekton-robot tekton-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/documentation Categorizes issue or PR as related to documentation. labels Sep 1, 2022
@tekton-robot tekton-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Sep 1, 2022
@JeromeJu JeromeJu force-pushed the 5330-v1-migration-doc branch 3 times, most recently from fbabdde to 68ca3dd Compare September 1, 2022 19:14
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Show resolved Hide resolved
The `resources` fields of Task, TaskRun, Pipeline and PipelineRun should not be used due to the deprecation of `PipelineResources`.

## Replacing `taskRef.bundle` and `pipelineRef.bundle` with Bundle Resolver
Bundle resolver in remote resolution should be used instead of `taskRun.spec.taskRef.bundle` and `pipelineRun.spec.pipelineRef.bundle`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This also requires enabling the enable-bundles-resolver feature flag; please link to https://github.com/tektoncd/pipeline/blob/main/docs/install.md#customizing-the-pipelines-controller-behavior

@abayer would you mind adding the new resolvers flags to that section?

value: Task
```

## Replacing ClusterTask with Remote Resolution
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you give an example of how a cluster task can be replaced with the cluster resolver?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good call, PR incoming.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ha, wait, I thought I was responding to #5415 (comment) 🤦 I'll wait for this and #5405 to land and then open a PR to do that. =)

abayer added a commit to abayer/tektoncd-pipeline that referenced this pull request Sep 1, 2022
…ation docs

Prompted by tektoncd#5415 (comment)

Signed-off-by: Andrew Bayer <andrew.bayer@gmail.com>
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved
@JeromeJu JeromeJu mentioned this pull request Sep 2, 2022
4 tasks
@tekton-robot tekton-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Sep 2, 2022
tekton-robot pushed a commit that referenced this pull request Sep 2, 2022
…ation docs

Prompted by #5415 (comment)

Signed-off-by: Andrew Bayer <andrew.bayer@gmail.com>
docs/migrating-v1beta1-to-v1.md Outdated Show resolved Hide resolved

```yaml
apiVersion: tekton.dev/v1beta1
kind: Taskrun
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
kind: Taskrun
kind: TaskRun

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this comment and the one below were not resolved

Copy link
Member Author

@JeromeJu JeromeJu Sep 9, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This might have happened because we changed this to TaskRun.yaml and removed the kind.

bundle: docker.io/ptasci67/example-oci@sha256:053a6cb9f3711d4527dd0d37ac610e8727ec0288a898d5dfbd79b25bcaa29828
---
apiVersion: tekton.dev/v1beta1
kind: Taskrun
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
kind: Taskrun
kind: TaskRun


## Replacing ClusterTask with Remote Resolution
`ClusterTask` is deprecated. Please use the `cluster` resolver instead, for example: ....
# TODO add example after #5404 is merged
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# TODO add example after #5404 is merged
# TODO(5330): add example after #5405 is merged

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this comment was resolved.

### Replacing a `cloudEvent` resource

You can replace a `cloudEvent` resource with the [`CloudEvent` Catalog `Task`](https://github.com/tektoncd/catalog/tree/main/task/cloudevent).
You can replace the `PipelineResources` with `Tasks` following the [reference](https://github.com/tektoncd/pipeline/blob/main/docs/pipelineresources.md)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
You can replace the `PipelineResources` with `Tasks` following the [reference](https://github.com/tektoncd/pipeline/blob/main/docs/pipelineresources.md)
See ["Replacing PipelineResources with Tasks"](https://github.com/tektoncd/pipeline/blob/main/docs/pipelineresources.md#replacing-pipelineresources-with-tasks) for information and examples on how to replace PipelineResources when migrating from v1alpha1 to v1beta1.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this was not resolved

docs/pipelineresources.md Show resolved Hide resolved
@tekton-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: lbernick

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

@tekton-robot tekton-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 6, 2022
This commit introduces a doc describing how to migrate from v1beta1 to v1.
It details changes of fields as well as deprecations.
@abayer
Copy link
Contributor

abayer commented Sep 6, 2022

/lgtm

@tekton-robot tekton-robot added the lgtm Indicates that a PR is ready to be merged. label Sep 6, 2022
@tekton-robot tekton-robot merged commit 39e345c into tektoncd:main Sep 6, 2022
@lbernick
Copy link
Member

lbernick commented Sep 8, 2022

@JeromeJu would you mind opening a follow-up PR addressing some of the comments I left here?

@JeromeJu
Copy link
Member Author

JeromeJu commented Sep 8, 2022

would you mind opening a follow-up PR addressing some of the comments I left here?

Will do. Thanks @lbernick for the reminder.

JeromeJu added a commit to JeromeJu/pipeline that referenced this pull request Sep 9, 2022
This commit follows up on tektoncd#5415 and resolves the respective comments.
JeromeJu added a commit to JeromeJu/pipeline that referenced this pull request Sep 9, 2022
This commit follows up on tektoncd#5415 and resolves the respective comments.
tekton-robot pushed a commit that referenced this pull request Sep 15, 2022
This commit follows up on #5415 and resolves the respective comments.
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. kind/documentation Categorizes issue or PR as related to documentation. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

v1beta1 -> v1 migration guide
4 participants