-
Notifications
You must be signed in to change notification settings - Fork 402
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
Add documentations for the release process of Helm charts #723
Merged
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Helm charts release | ||
|
||
We host all Helm charts on [kuberay-helm](https://github.com/ray-project/kuberay-helm). This document describes the process for release managers to release Helm charts. | ||
|
||
## The end-to-end workflow | ||
### Step 1: Update version in Chart.yaml | ||
Please update the value of `version` in [ray-cluster/Chart.yaml](https://github.com/ray-project/kuberay/blob/master/helm-chart/ray-cluster/Chart.yaml), [kuberay-operator/Chart.yaml](https://github.com/ray-project/kuberay/blob/master/helm-chart/kuberay-operator/Chart.yaml), and [kuberay-apiserver/Chart.yaml](https://github.com/ray-project/kuberay/blob/master/helm-chart/kuberay-apiserver/Chart.yaml) to the new release version (e.g. 0.4.0). | ||
|
||
### Step 2: Copy the helm-chart directory from kuberay to kuberay-helm | ||
In [kuberay-helm CI](https://github.com/ray-project/kuberay-helm/blob/main/.github/workflows/chart-release.yaml), `helm/chart-releaser-action` will create releases for all charts in the directory `helm-chart` and update `index.yaml` in the [gh-pages](https://github.com/ray-project/kuberay-helm/tree/gh-pages) branch when the PR is merged into `main`. Note that `index.yaml` is necessary when you run the command `helm repo add`. I recommend removing the `helm-chart` directory in the kuberay-helm repository and creating a new one by copying from the kuberay repository. | ||
|
||
### Step 3: Check the correctness | ||
When the PR is merged into `main`, the releases and `index.yaml` will be generated. You can check the correctness by: | ||
|
||
* Check whether the [releases](https://github.com/ray-project/kuberay-helm/releases) are created as expectation. | ||
* Check whether [index.yaml](https://github.com/ray-project/kuberay-helm/blob/gh-pages/index.yaml) exists or not. | ||
* Check whether [index.yaml](https://github.com/ray-project/kuberay-helm/blob/gh-pages/index.yaml) has metadata of all releases, including old versions. | ||
* Check the creation/update time of all releases and `index.yaml` to ensure they are updated. | ||
|
||
* Install charts from Helm repository. | ||
```sh | ||
helm repo add kuberay https://ray-project.github.io/kuberay-helm/ | ||
|
||
# List all charts | ||
helm search repo kuberay | ||
|
||
# Install charts | ||
helm install kuberay-operator kuberay/kuberay-operator | ||
helm install kuberay-apiserver kuberay/kuberay-apiserver | ||
helm install ray-cluster kuberay/ray-cluster | ||
``` | ||
|
||
## Delete the existing releases | ||
`helm/chart-releaser-action` does not encourage users to delete existing releases; thus, `index.yaml` will not be updated automatically after the deletion. If you really need to do that, please read this section carefully before you do that. | ||
|
||
* Delete the [releases](https://github.com/ray-project/kuberay-helm/releases) | ||
* Remove the related tags by the following command. If tags are not properly removed, [ray-project/kuberay/#561](https://github.com/ray-project/kuberay/issues/561) may occur. | ||
|
||
```sh | ||
# git remote -v | ||
# upstream [email protected]:ray-project/kuberay-helm.git (fetch) | ||
# upstream [email protected]:ray-project/kuberay-helm.git (push) | ||
|
||
# The following command deletes the tag "ray-cluster-0.4.0". | ||
git push --delete upstream ray-cluster-0.4.0 | ||
``` | ||
* Remove `index.yaml` | ||
* Trigger kuberay-helm CI again to create new releases and new index.yaml. | ||
* Follow "Step3: Check the correctness" to test it. |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need to delete existing releases?
Should we maintain Helm release version for each KubeRay release?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because the
chart-releaser
will only be triggered when the PR is merged intomain
, maintainers may want to revert some wrong PRs. For example, a release manager of 0.4.0 forgets to updateversion
from 0.3.0 to 0.4.0 in Chart.yaml, so the existing 0.3.0 releases andindex.yaml
update. In this case, we need to follow the "Delete the existing releases" section to revert.Yes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, makes sense -- could you clarify that deleting charts is only for such situations?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, I think it already sufficiently conveys that deleting things is not recommended.