Day 1 Ops: Install, Update, Uninstall#

  1. Install instance sample

    To demonstrate, we use the instance chart and set a domain, so we will be able to log into the web client right away if we redirected this domain correctly.

    The chart version is the nplus version (for example 26.4.1005); --version pins it, without --version you get the latest release. Which nscale version runs is decided by a version file from the versions directory, stacked with --values. Without a version file, you get the newest nscale version (versions/latest.yaml). See VERSIONING.md.

    You can easily adopt the examples to your environment.

    helm install sample nplus/nplus-instance \
      --set global.ingress.domain=sample.nplus.cloud \
      --values versions/10.2.1400.yaml
  2. Rolling update of instance sample to a later monthly release

    All nscale components support rolling updates, but the nscale Application Layer. As the Application Layer has the connection to the database, and this depends on the DB scheme, only cluster members with the same version can work with that DB at the same time.

    There are no scheme updates in monthly releases, so we can use the default rolling updates here.

    helm upgrade sample nplus/nplus-instance \
      --set global.ingress.domain=sample.nplus.cloud \
      --values versions/10.2.1500.yaml
  3. Minor / Major Update of instance sample

    Minor or Major updates require the nscale Application Layer to have the same version on all cluster nodes. And since the nscale Pipeliner may also have an integrated nappl in core mode, we also need to update the pipeliner at the same time.

    We first need to shut down all nappl cluster members, so set the nscale Application Layer, the potential nappl Jobs Node and the nscale Pipeliner stateful sets to replica 0.

    In nplus, these replicaSets are labeled with nplus/type=core, so we can easily select them:

    kubectl scale statefulset -l nplus/type=core,nplus/instance=sample --replicas=0

    After that, the update is just like a monthly release:

    helm upgrade sample nplus/nplus-instance \
      --set global.ingress.domain=sample.nplus.cloud \
      --values versions/10.3.1001.yaml

As nplus does not know if you run the Pipeliner in core mode, make sure you change the default type pipeliner to core when installing, indicating that this pipeliner node needs to be scaled down as well.

  1. Uninstall the instance sample

    helm uninstall sample

Install, Update, Uninstall with argoCD#

  1. Install instance sample-argo

    helm install sample-argo nplus/nplus-instance-argo \
      --set global.ingress.domain=sample-argo.nplus.cloud \
      --values versions/10.2.1400.yaml
  2. Rolling update of instance sample-argo to a later monthly release

    helm upgrade sample-argo nplus/nplus-instance-argo \
      --set global.ingress.domain=sample-argo.nplus.cloud \
      --values versions/10.2.1500.yaml
  3. Minor / Major Update of instance sample-argo

    The difference to a deployment without argoCD is, that if we manually scale down the nappl cluster nodes, argoCD tries to immediately heal this discrepancy between the description and the status. So we first switch off this healing mechanism, to be able to scale down:

    kubectl -n argocd  patch --type='merge' application sample-argo -p "{\"spec\":{\"syncPolicy\":null}}" 

    After that, it is the same update procedure as we have with a standard deployment:

    kubectl scale statefulset -l nplus/type=core,nplus/instance=sample-argo --replicas=0
    helm upgrade sample-argo nplus/nplus-instance-argo \
      --set global.ingress.domain=sample-argo.nplus.cloud \
      --values versions/10.3.1001.yaml

    When done, we switch the healing back on which will start to re-sync and recreate all cluster members with the new version:

    kubectl -n argocd patch --type=merge application sample-argo -p "{\"spec\":{\"syncPolicy\":{\"automated\":{\"prune\":true,\"selfHeal\":true}}}}"
  4. Uninstall the instance sample-argo

    helm uninstall sample-argo