Skip to content

Latest commit

 

History

History
101 lines (79 loc) · 4.5 KB

RELEASING.adoc

File metadata and controls

101 lines (79 loc) · 4.5 KB

Releasing Kiali UI

Kiali is released using a Jenkins Pipeline. The main document covering the release process can be found here.

Versioning scheme

The versioning scheme that we are following is similar to semver, but not as strict, given both that we are not 1.0 yet and that we are the end product, in the sense that nothing should depend on us to do anything. For now, and that might change in the future, our API is private and we make no guarantees that compatibility is going to be maintaned.

For our versioning scheme, the major part means a major release, and that’s decided in advance by the team. The minor means new features are included with the release, and the patch version covers only bugfixes.

The UI and the core might be out of sync in patch versions, but they should be in sync for minor. That means that, if the UI is 0.5.10, then any core version on 0.5.X should work with it, but that are no guarantees that it will work with core 0.4.X or core 0.6.X.

Of course, that’s a soft limitation, and your mileage may vary. Sometimes it might work just fine, we just don’t give any guarantees that it will.

Running the release process locally

If you don’t have access to the Jenkins instance or the release process through Jenkins doesn’t suit your needs, you may want to run the release process locally.

This guide covers releasing only kiali-ui.

Requirements

You must have write permissions to the kiali-ui public GitHub repository in order to be able to push the tags. You will also need an NPM account that is able to publish to the NPM @kiali organization.

You will need a working dev environment for kiali-ui (git, npm, yarn, etc). You will also need the following tools available in your $PATH:

  • jq - a JSON processor used to update the package.json file

  • semver shell utility - used to update version numbers

  • make - to run the release process

  • curl - because the release process places PRs using the GitHub API

If you want the release process to push a PR for you to prepare the code for the next release, you will need a GitHub Token for your account.

It’s assumed that you are running the release process in your fork of the kiali-ui repository.

Making the release

  1. Login to NPM using the user with write access to the NPM @kiali organization:

    • npm login

  2. Checkout the code that you want to release:

    • git checkout branch_to_release (usually, you should release "master")

    • Be advised that the release process will commit changes locally.

  3. The release process may need to create a PR to prepare the code for the next version. A GitHub token is required to create the PR:

    • export GH_TOKEN={your_github_token}

    • This is optional. If a token is not provided, a branch is created in your fork of the code, if needed. Then, you can place the PR manually.

  4. Run the release process:

    • make -f Makefile.jenkins release

By default, it’s assumed that you are doing a minor release. If want to do another type of release, you can run the release process specifying the RELEASE_TYPE variable. Valid values are "major", "minor", "patch", "edge" and "snapshot.X". For example:

  • RELEASE_TYPE="snapshot.1" make -f Makefile.jenkins release

Note: The process will adjust the version string as needed, according to the type of release. Please, don’t try to adjust the version string (i.e. don’t change the version in package.json).

Available options

  • If you want to make a "dry-run" of the release:

    • NPM_DRY_RUN=y make -f Makefile.jenkins release

  • In minor or patch mode, the release process updates or creates a version branch in the kiali-ui repository (the branch name is like "vMAJOR.MINOR"). You can omit this:

    • OMIT_VERSION_BRANCH=y make -f Makefile.jenkins release

  • In minor or patch mode, the release process may create a branch in your fork of the repository with the required changes to prepare the code for the next release. The branch is created if it isn’t possible to push to the kiali-ui repository. By default, the name of the branch is prepare_next_version. If you want to customize the name of the branch:

    • BUMP_BRANCH_ID={branch_name} make -f Makefile.jenkins release

  • If your NPM account don’t have write privileges to the @kiali organization but you have a token with the required privileges, you can use that token:

    • NPM_TOKEN="{your_token}" make -f Makefile.jenkins release