Skip to content

Commit

Permalink
Update the release cheatsheet to the new release drafter
Browse files Browse the repository at this point in the history
With tektoncd/plumbing#1019 the release
draft process is now a pipeline as it does not use pipeline
resources anymore. The new template also include support for
rekor. Update the cheatsheet accordingly.

Signed-off-by: Andrea Frittoli <andrea.frittoli@uk.ibm.com>
  • Loading branch information
afrittoli authored and tekton-robot committed Mar 17, 2022
1 parent 6caa150 commit 1294e92
Showing 1 changed file with 20 additions and 24 deletions.
44 changes: 20 additions & 24 deletions tekton/release-cheat-sheet.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,15 @@ the pipelines repo, a terminal window and a text editor.
| jq ".[].name"
```
1. Find the Rekor UUID for the release
```bash
RELEASE_FILE=https://storage.googleapis.com/tekton-releases/pipeline/previous/${TEKTON_VERSION}/release.yaml
CONTROLLER_IMAGE_SHA=$(curl $RELEASE_FILE | egrep 'gcr.io.*controller' | cut -d'@' -f2)
REKOR_UUID=$(rekor-cli search --sha $CONTROLLER_IMAGE_SHA | grep -v Found | head -1)
echo -e "CONTROLLER_IMAGE_SHA: ${CONTROLLER_IMAGE_SHA}\nREKOR_UUID: ${REKOR_UUID}"
```
1. Create additional environment variables
```bash
Expand All @@ -94,36 +103,20 @@ the pipelines repo, a terminal window and a text editor.
TEKTON_PACKAGE=tektoncd/pipeline
```
1. Create a `PipelineResource` of type `git`
```shell
cat <<EOF | kubectl --context dogfooding create -f -
apiVersion: tekton.dev/v1alpha1
kind: PipelineResource
metadata:
name: tekton-pipelines-$(echo $TEKTON_VERSION | tr '.' '-')
namespace: default
spec:
type: git
params:
- name: url
value: 'https://github.com/tektoncd/pipeline'
- name: revision
value: ${TEKTON_RELEASE_GIT_SHA}
EOF
```
1. Execute the Draft Release task.
1. Execute the Draft Release Pipeline.
```bash
tkn --context dogfooding task start \
-i source="tekton-pipelines-$(echo $TEKTON_VERSION | tr '.' '-')" \
-i release-bucket=pipeline-tekton-bucket \
tkn --context dogfooding pipeline start \
--workspace name=shared,volumeClaimTemplateFile=workspace-template.yaml \
--workspace name=credentials,secret=release-secret \
-p package="${TEKTON_PACKAGE}" \
-p git-revision="$TEKTON_RELEASE_GIT_SHA" \
-p release-tag="${TEKTON_VERSION}" \
-p previous-release-tag="${TEKTON_OLD_VERSION}" \
-p release-name="${TEKTON_RELEASE_NAME}" \
create-draft-release
-p bucket="gs://tekton-releases/pipeline" \
-p rekor-uuid="$REKOR_UUID" \
release-draft
```
1. Watch logs of create-draft-release
Expand Down Expand Up @@ -163,6 +156,9 @@ the pipelines repo, a terminal window and a text editor.
1. Update [the catalog repo](https://github.com/tektoncd/catalog) test infrastructure
to use the new release by updating the `RELEASE_YAML` link in [e2e-tests.sh](https://github.com/tektoncd/catalog/blob/master/test/e2e-tests.sh).
1. For major releases, the [website sync configuration](https://github.com/tektoncd/website/blob/main/sync/config/pipelines.yaml)
to include the new release.
Congratulations, you're done!
## Setup dogfooding context
Expand Down

0 comments on commit 1294e92

Please sign in to comment.