Skip to content

Latest commit

 

History

History
66 lines (59 loc) · 3.26 KB

File metadata and controls

66 lines (59 loc) · 3.26 KB

!! NOTE: This section needs to be revised

Release Process

This doc covers the release process for the functions in the krm-functions-catalog repo.

  1. Checking the CI status of the main branch. If the CI is failing on the main, we need to fix it before doing a release.
  2. Go to the releases pages in your browser.
  3. Click Draft a new release to create a new release for a function. The tag version format should be functions/{language}/{function-name}/{semver}. e.g. functions/go/set-namespace/v1.2.3. The release name should be {funtion-name} {semver}. The release notes for this function should be in the body.
  4. Click Publish release button.
  5. Verify the new functions are released in ghcr.io/kptdev/krm-functions-catalog/{funtion-name}/{semver} or, if using the GitHub based CD flow, check the relevant GitHub packages section
  6. Send an announcement on the kpt slack channel

⚠️ Warning: The update docs section is currently being revised. DO NOT USE!!

Updating function docs

After creating a release, the docs for the function should be updated to reflect the latest patch version. A script has been created to automate this process. The RELEASE_BRANCH branch should already exist in the repo and a tag should be created on the releases pages. RELEASE_BRANCH is in the form of ${FUNCTION_NAME}/v${MAJOR_VERSION}.${MINOR_VERSION}. For example set-namespace/v0.3, kubeval/v0.1, etc.

  1. Setup the release branch Release branch should have existed in the upstream repo in the form of <FUNCTION_NAME>/v<MAJOR>.<MINOR>. Let's take set-namespace/v0.4 as an example. You should replace that to your RELEASE_BRANCH.
    > export RELEASE_BRANCH=set-namespace/v0.4
  2. Clean up the local branch The release script needs to run in the local . To avoid git ref conflicts, we suggest you delete your local branch OR make it up to date with the remote
> git branch -D ${RELEASE_BRANCH}
  1. Fetch the upstream repository Your upstream repo should point to the official krm-functions-catalog. Verify your git remote is set as below
> git remote -v | grep upstream
upstream	git@github.com:kptdev/krm-functions-catalog.git (fetch)
upstream	git@github.com:kptdev/krm-functions-catalog.git (push)
# Fetch the latest upstream repo
> git fetch upstream
  1. Run the doc updating script.
git checkout remotes/upstream/main
RELEASE_BRANCH=${RELEASE_BRANCH} make update-function-docs
  1. Send out a Pull Request. Your local git reference is now pointing to the local RELEASE BRANCH. A new git commit is auto-generated which contains the function document referring to the latest function version in the form of <FUNCTION_NAME>/v<MAJOR>.<MINOR>.<PATCH> You should be ready to submit the Pull Request against the upstream <RELEASE_BRANCH>.
> git push -f origin ${RELEASE_BRANCH}