Switch release channel

This section describes how to switch between different release channels for Rok. In the following commands, we assume that you currently track the release-1.1 channel and you want to upgrade your deployments repo to track the release-1.2 release channel.

  1. Go to your GitOps repository, inside your rok-tools management environment:

    root@rok-tools:/# cd ~/ops/deployments
  2. Ensure that you are currently on the correct release channel:

    root@rok-tools::~/ops/deployments# git rev-parse --abbrev-ref --symbolic-full-name @{u}
  3. Prepare your branch for the upcoming rebase, with the rok-kf-rebase tool:

    root@rok-tools:~/ops/deployments# rok-kf-rebase
  4. After rok-kf-rebase completes, verify that the intermediate rebase branch was created:

    root@rok-tools:~/ops/deployments# git show --shortstat release-1.2-base
    commit 7ac4720df93325399aea44519bf69b55fec83e03 (release-1.2-base)
    Author: Rok Kubeflow Rebase <no-reply@arrikto.com>
    Date:   Wed May 12 10:49:52 2021 +0000
        Renaming commit
     1614 files changed, 0 insertions(+), 0 deletions(-)
  5. Switch to the release-1.2 channel and rebase your work on top of that:

    root@rok-tools:~/ops/deployments# git -c merge.directoryRenames=false -c merge.renameLimit=99999 rebase -Xtheirs --onto origin/release-1.2 release-1.2-base
  6. Configure your local branch to track the new release channel:

    root@rok-tools:~/ops/deployments# git branch --set-upstream-to=origin/release-1.2
  7. Delete the intermediate rebase branch:

    root@rok-tools:~/ops/deployments# git branch -D release-1.2-base