Skip to content

Commit 1107cb6

Browse files
Merge pull request #1993 from maelvls/update-release-process
Release process: update after releasing v1.20.0-beta.0 with Hemant
2 parents 3b2826d + a426964 commit 1107cb6

File tree

1 file changed

+55
-151
lines changed

1 file changed

+55
-151
lines changed

content/docs/contributing/release-process.md

Lines changed: 55 additions & 151 deletions
Original file line numberDiff line numberDiff line change
@@ -302,6 +302,21 @@ page if a step is missing or if it is outdated.
302302
permission, you will have to open a PR to merge master into the release
303303
branch), and wait for the PR checks to become green.
304304
305+
- **(initial beta only)** Create a PR on the release branch you just created
306+
to edit the file `make/_shared/klone/01_mod.mk`:
307+
308+
```diff
309+
-shared_generate_targets += generate-klone
310+
+# MANUAL CHANGE!
311+
+# generate-klone is removed so we can manually update versions
312+
+# and diverge from upstream klone
313+
+# shared_generate_targets += generate-klone
314+
```
315+
316+
This is required to prevent future Go version bumps on the release branch
317+
from being reverted by `make generate`. Example PR:
318+
[#8578](https://github.com/cert-manager/cert-manager/pull/8578).
319+
305320
- **(subsequent beta, patch release and final release)**: place yourself on
306321
the release branch:
307322
@@ -350,83 +365,7 @@ page if a step is missing or if it is outdated.
350365
> will have to open a PR to merge master into the release branch), and
351366
> wait for the PR checks to become green.
352367

353-
> **Note 2:** For recent versions of cert-manager, the tag being pushed will trigger a Google Cloud Build job to start,
354-
> kicking off a build using the steps in `gcb/build_cert_manager.yaml`. Users with access to
355-
> the cert-manager-release project on GCP should be able to view logs in [GCB build history](https://console.cloud.google.com/cloud-build/builds?project=cert-manager-release).
356-
357-
9. <details>
358-
<summary>**ONLY for (1.12, 1.13, and 1.14)**</summary>
359-
360-
In this step, we make sure the Go module
361-
`github.com/cert-manager/cert-manager/cmd/ctl` can be imported by
362-
third-parties.
363-
364-
First, create a temporary branch.
365-
366-
```bash
367-
# Must be run from the cert-manager repo folder.
368-
git checkout -b "update-cmd/ctl/$RELEASE_VERSION"
369-
```
370-
371-
Second, update the `cmd/ctl`'s `go.mod` with the tag we just created:
372-
373-
```bash
374-
# Must be run from the cert-manager repo folder.
375-
cd cmd/ctl
376-
go get github.com/cert-manager/cert-manager@$RELEASE_VERSION
377-
cd ../..
378-
379-
make tidy
380-
git add "**/go.mod" "**/go.sum"
381-
git commit --signoff -m"Update cmd/ctl's go.mod to $RELEASE_VERSION"
382-
```
383-
384-
Then, push the branch to your fork of cert-manager. For example:
385-
386-
```bash
387-
# Must be run from the cert-manager repo folder.
388-
gh repo fork --remote-name fork
389-
git push -u fork "update-cmd/ctl/$RELEASE_VERSION"
390-
```
391-
392-
Then, open a PR to merge that change and go back to the release branch with
393-
the following commands:
394-
395-
```bash
396-
gh pr create \
397-
--title "[Release $RELEASE_VERSION] Update cmd/cmctl's go.mod to $RELEASE_VERSION" \
398-
--body-file - --base $BRANCH <<EOF
399-
This PR cmd/cmctl's go.mod to $RELEASE_VERSION as part of the release process.
400-
401-
**To the reviewer:** the version changes in \`go.mod\` must be reviewed.
402-
403-
\`\`\`release-note
404-
NONE
405-
\`\`\`
406-
EOF
407-
```
408-
409-
Wait for the PR to be merged.
410-
411-
Finally, create a tag for the `cmd/ctl` module:
412-
413-
```bash
414-
# Must be run from the cert-manager repo folder.
415-
git fetch origin $BRANCH
416-
git checkout $BRANCH
417-
git pull --ff-only origin $BRANCH
418-
git tag -m"cmd/ctl/$RELEASE_VERSION" "cmd/ctl/$RELEASE_VERSION" origin/$BRANCH
419-
git push origin "cmd/ctl/$RELEASE_VERSION"
420-
```
421-
422-
> **Note:** the reason we need to do this is explained on Stack Overflow:
423-
[how-are-versions-of-a-sub-module-managed][]
424-
425-
[how-are-versions-of-a-sub-module-managed]: https://stackoverflow.com/questions/60601011/how-are-versions-of-a-sub-module-managed/60601402#60601402
426-
427-
</details>
428-
429-
10. In this section, we create the description for the GitHub Release and some release notes for the website.
368+
9. In this section, we create the description for the GitHub Release and some release notes for the website.
430369

431370
> **Note:** This step is about creating the description that will be
432371
> copy-pasted into the GitHub release page. The creation of the "Release
@@ -473,90 +412,55 @@ page if a step is missing or if it is outdated.
473412

474413
4. Update the relevant release notes file on the website repo to include the contents of `website-release-notes.md`.
475414

476-
11. Check that the build that was automatically triggered when you pushed the
477-
tag is complete and send Slack messages about the release:
478-
479-
1. Send a first Slack message to `#cert-manager-dev`:
480-
481-
:::info
482-
483-
Releasing `1.2.0-alpha.2` 🧵
484-
485-
:::
486-
487-
2. Check that the build completed in the
488-
[GCB Build History](https://console.cloud.google.com/cloud-build/builds?project=cert-manager-release).
415+
10. Send a Slack message to `#cert-manager-dev` to announce that you are starting the release:
489416

490417
:::info
491418

492-
🔰 Please have a quick look at the build log as it might contain some unredacted
493-
data that we forgot to hide. We try to make sure the sensitive data is
494-
properly redacted but sometimes we forget to update this.
419+
Releasing `v1.20.0` 🧵
495420

496421
:::
497422

498-
3. Copy the build logs URL and send a second Slack message in reply to this
499-
first message with the Cloud Build job link. For example, the message
500-
might look like:
501-
502-
:::info
503-
504-
`cmrel makestage` build logs: https://console.cloud.google.com/cloud-build/builds/7641734d-fc3c-42e7-9e4c-85bfc4d1d547?project=1021342095237
505-
506-
:::
507-
508-
12. Run `cmrel publish`:
509-
510-
1. Do a `cmrel publish` dry-run to ensure that all the staged resources are
511-
valid. Run the following command:
512-
513-
```bash
514-
# Must be run from the "cert-manager/release" repo folder.
515-
cmrel publish --release-name "$RELEASE_VERSION"
516-
```
517-
518-
You can view the progress by clicking the Google Cloud Build URL in the
519-
output of this command.
520-
521-
2. While the build is running, send a third Slack message in reply to the first message:
423+
11. Go through the `cmrel` publish process:
522424

523-
:::info
524-
525-
Follow the `cmrel publish` dry-run build: https://console.cloud.google.com/cloud-build/builds16f6f875-0a23-4fff-b24d-3de0af207463?project=1021342095237
425+
1. Check that the build that was automatically triggered when you pushed the
426+
tag is complete in the
427+
[GCB Build History](https://console.cloud.google.com/cloud-build/builds?project=cert-manager-release).
526428

527-
:::
429+
2. Run the following command:
528430

529-
3. Now publish the release artifacts for real. The following command will publish the artifacts to GitHub, `Quay.io` and to our
530-
[helm chart repository](https://charts.jetstack.io):
531-
532-
```bash
533-
# Must be run from the "cert-manager/release" repo folder.
534-
cmrel publish --nomock --release-name "$RELEASE_VERSION"
535-
```
536-
537-
:::info
431+
```bash
432+
# Must be run from the "cert-manager/release" repo folder.
433+
cmrel publish --release-name "$RELEASE_VERSION"
434+
```
538435

539-
⏰ Upon completion there will be:
540-
<ol>
541-
<li>
542-
<a href="https://github.com/cert-manager/cert-manager/releases">A draft release of cert-manager on GitHub</a>
543-
</li>
544-
<li>
545-
<a href="https://github.com/jetstack/jetstack-charts/pulls">A pull request containing the new Helm chart</a>
546-
</li>
547-
</ol>
436+
This will run `cmrel publish` in dry-run mode to ensure that all the staged
437+
resources are valid. You can view the progress by clicking the Google Cloud
438+
Build URL in the output of this command.
548439

549-
:::
440+
3. Now publish the release artifacts for real. The following command will
441+
publish the artifacts to GitHub, `Quay.io` and to our [Helm chart
442+
repository](https://charts.jetstack.io):
550443

551-
4. While the build is running, send a fourth Slack message in reply to the first message:
444+
```bash
445+
# Must be run from the "cert-manager/release" repo folder.
446+
cmrel publish --nomock --release-name "$RELEASE_VERSION"
447+
```
552448

553-
:::info
449+
:::info
554450

555-
Follow the `cmrel publish` build: https://console.cloud.google.com/cloud-build/builds/b6fef12b-2e81-4486-9f1f-d00592351789?project=1021342095237
451+
⏰ Upon completion there will be:
452+
<ol>
453+
<li>
454+
<a href="https://github.com/cert-manager/cert-manager/releases">A draft release of cert-manager on GitHub</a>
455+
</li>
456+
<li>
457+
<a href="https://github.com/jetstack/jetstack-charts/pulls">A pull request containing the new Helm chart</a>
458+
</li>
459+
</ol>
556460

557-
:::
461+
:::
558462

559-
13. Publish the GitHub release:
463+
12. Publish the GitHub release:
560464

561465
1. Visit the draft GitHub release and paste `github-release-description.md` that you
562466
generated earlier. You will need to manually edit the content to match
@@ -570,7 +474,7 @@ page if a step is missing or if it is outdated.
570474
571475
4. Click "Publish" to make the GitHub release live.
572476
573-
14. Merge the pull request containing the Helm chart:
477+
13. Merge the pull request containing the Helm chart:
574478
575479
Important: This PR can currently only be merged by CyberArk employees, but we're aiming to fix that soon. Changing this
576480
will involve us coming up with a plan for migrating where our Helm charts are stored and ensuring we don't break anyone.
@@ -591,7 +495,7 @@ page if a step is missing or if it is outdated.
591495
5. Merge the PR
592496
6. Check that the [cert-manager Helm chart is visible on ArtifactHUB](https://artifacthub.io/packages/helm/cert-manager/cert-manager).
593497
594-
15. Upload the Helm chart to the OCI registry:
498+
14. Upload the Helm chart to the OCI registry:
595499
596500
1. Run the following command to upload the Helm chart to the OCI registry, and sign it with cosign:
597501
@@ -610,7 +514,7 @@ page if a step is missing or if it is outdated.
610514
611515
Look for config, content and provenance layers in the output.
612516
613-
16. **(final + patch releases)** Merge the 4 Website PRs:
517+
15. **(final + patch releases)** Merge the 4 Website PRs:
614518
615519
1. Merge the PRs "Release Notes", "Upgrade Notes", and "Freeze And Bump
616520
Versions" that you have created previously.
@@ -628,7 +532,7 @@ page if a step is missing or if it is outdated.
628532
629533
[ff-release-next]: https://github.com/cert-manager/website/compare/master...release-next?quick_pull=1&title=%5BPost-Release%5D+Merge+release-next+into+master&body=%3C%21--%0A%0AThe+command+%22%2Foverride+dco%22+is+necessary+because+some+the+merge+commits%0Ahave+been+written+by+the+bot+and+do+not+have+a+DCO+signoff.%0A%0A--%3E%0A%0A%2Foverride+dco
630534
631-
17. Post a Slack message as an answer to the first message. Toggle the check
535+
16. Post a Slack message as a reply to the first message. Toggle the check
632536
box "Also send to `#cert-manager-dev`" so that the message is well
633537
visible. Also cross-post the message on `#cert-manager`.
634538
@@ -638,7 +542,7 @@ page if a step is missing or if it is outdated.
638542
639543
:::
640544
641-
18. **(final release only)** Show the release to the world:
545+
17. **(final release only)** Show the release to the world:
642546
643547
1. Send an email to
644548
[`cert-manager-dev@googlegroups.com`](https://groups.google.com/g/cert-manager-dev)
@@ -654,7 +558,7 @@ page if a step is missing or if it is outdated.
654558
4. Create a post on the cert-manager BlueSky account! Login details are in the cert-manager 1password.
655559
([Example post](https://bsky.app/profile/cert-manager.bsky.social/post/3lhdtn7c2222u))
656560
657-
19. Proceed to the post-release "testing and release" steps:
561+
18. Proceed to the post-release "testing and release" steps:
658562
659563
1. **(initial beta only)** Create a PR on
660564
[cert-manager/testing](https://github.com/cert-manager/testing) in order to

0 commit comments

Comments
 (0)