You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

83 lines
4.8 KiB

  1. # Release Process
  2. The Kubespray Project is released on an as-needed basis. The process is as follows:
  3. 1. An issue is proposing a new release with a changelog since the last release. Please see [a good sample issue](https://github.com/kubernetes-sigs/kubespray/issues/8325)
  4. 2. At least one of the [approvers](OWNERS_ALIASES) must approve this release
  5. 3. The `kube_version_min_required` variable is set to `n-1`
  6. 4. Remove hashes for [EOL versions](https://github.com/kubernetes/website/blob/main/content/en/releases/patch-releases.md) of kubernetes from `*_checksums` variables.
  7. 5. Create the release note with [Kubernetes Release Notes Generator](https://github.com/kubernetes/release/blob/master/cmd/release-notes/README.md). See the following `Release note creation` section for the details.
  8. 6. An approver creates [new release in GitHub](https://github.com/kubernetes-sigs/kubespray/releases/new) using a version and tag name like `vX.Y.Z` and attaching the release notes
  9. 7. An approver creates a release branch in the form `release-X.Y`
  10. 8. The corresponding version of [quay.io/kubespray/kubespray:vX.Y.Z](https://quay.io/repository/kubespray/kubespray) and [quay.io/kubespray/vagrant:vX.Y.Z](https://quay.io/repository/kubespray/vagrant) container images are built and tagged. See the following `Container image creation` section for the details.
  11. 9. The `KUBESPRAY_VERSION` variable is updated in `.gitlab-ci.yml`
  12. 10. The release issue is closed
  13. 11. An announcement email is sent to `dev@kubernetes.io` with the subject `[ANNOUNCE] Kubespray $VERSION is released`
  14. 12. The topic of the #kubespray channel is updated with `vX.Y.Z is released! | ...`
  15. ## Major/minor releases and milestones
  16. * For major releases (vX.Y) Kubespray maintains one branch (`release-X.Y`). Minor releases (vX.Y.Z) are available only as tags.
  17. * Security patches and bugs might be backported.
  18. * Fixes for major releases (vX.Y) and minor releases (vX.Y.Z) are delivered
  19. via maintenance releases (vX.Y.Z) and assigned to the corresponding open
  20. [GitHub milestone](https://github.com/kubernetes-sigs/kubespray/milestones).
  21. That milestone remains open for the major/minor releases support lifetime,
  22. which ends once the milestone is closed. Then only a next major or minor release
  23. can be done.
  24. * Kubespray major and minor releases are bound to the given `kube_version` major/minor
  25. version numbers and other components' arbitrary versions, like etcd or network plugins.
  26. Older or newer component versions are not supported and not tested for the given
  27. release (even if included in the checksum variables, like `kubeadm_checksums`).
  28. * There is no unstable releases and no APIs, thus Kubespray doesn't follow
  29. [semver](https://semver.org/). Every version describes only a stable release.
  30. Breaking changes, if any introduced by changed defaults or non-contrib ansible roles'
  31. playbooks, shall be described in the release notes. Other breaking changes, if any in
  32. the contributed addons or bound versions of Kubernetes and other components, are
  33. considered out of Kubespray scope and are up to the components' teams to deal with and
  34. document.
  35. * Minor releases can change components' versions, but not the major `kube_version`.
  36. Greater `kube_version` requires a new major or minor release. For example, if Kubespray v2.0.0
  37. is bound to `kube_version: 1.4.x`, `calico_version: 0.22.0`, `etcd_version: v3.0.6`,
  38. then Kubespray v2.1.0 may be bound to only minor changes to `kube_version`, like v1.5.1
  39. and *any* changes to other components, like etcd v4, or calico 1.2.3.
  40. And Kubespray v3.x.x shall be bound to `kube_version: 2.x.x` respectively.
  41. ## Release note creation
  42. You can create a release note with:
  43. ```shell
  44. export GITHUB_TOKEN=<your-github-token>
  45. export ORG=kubernetes-sigs
  46. export REPO=kubespray
  47. release-notes --start-sha <The start commit-id> --end-sha <The end commit-id> --dependencies=false --output=/tmp/kubespray-release-note --required-author=""
  48. ```
  49. If the release note file(/tmp/kubespray-release-note) contains "### Uncategorized" pull requests, those pull requests don't have a valid kind label(`kind/feature`, etc.).
  50. It is necessary to put a valid label on each pull request and run the above release-notes command again to get a better release note
  51. ## Container image creation
  52. The container image `quay.io/kubespray/kubespray:vX.Y.Z` can be created from Dockerfile of the kubespray root directory:
  53. ```shell
  54. cd kubespray/
  55. nerdctl build -t quay.io/kubespray/kubespray:vX.Y.Z .
  56. nerdctl push quay.io/kubespray/kubespray:vX.Y.Z
  57. ```
  58. The container image `quay.io/kubespray/vagrant:vX.Y.Z` can be created from build.sh of test-infra/vagrant-docker/:
  59. ```shell
  60. cd kubespray/test-infra/vagrant-docker/
  61. ./build vX.Y.Z
  62. ```
  63. Please note that the above operation requires the permission to push container images into quay.io/kubespray/.
  64. If you don't have the permission, please ask it on the #kubespray-dev channel.