Skip to content

Moving to the new cluster

Kestrel is moving to a new cluster on the renewed Arbutus cloud, and the current cluster becomes the legacy cluster until it shuts down. Both run side by side while you move. Your tenant, members, quotas, certificate enablement and hostnames carry over, and the new cluster runs the same platform configuration. You redeploy your workloads and move your data yourself; RCS moves your tenant hostnames when you email RCS.

DateWhat happensWhat you do
TBDThe new cluster opens at kestrel-prod.arbutus.cloudAdd a kestrel-new context, then migrate
TBDThe switch: kestrel.arbutus.cloud moves to the new cluster, and custom domains that point at it move tooBe cut over, or cut over at this moment
TBDThe rename: ArgoCD, Grafana and kubectl on the new cluster move to kestrel.arbutus.cloudUse your kestrel context again
TBDShutdown: the legacy cluster is deleted with everything on it. Nothing is kept.Be cut over before this date
Legacy cluster, until the switchNew cluster, until the renameNew cluster, after the rename
kubectlyour kestrel context: https://proxy.kestrel.arbutus.cloudnew kestrel-new context: https://proxy.kestrel-prod.arbutus.cloudyour kestrel context
ArgoCDhttps://kestrel.arbutus.cloud/argocdhttps://kestrel-prod.arbutus.cloud/argocdhttps://kestrel.arbutus.cloud/argocd
Grafanahttps://kestrel.arbutus.cloud/grafanahttps://kestrel-prod.arbutus.cloud/grafanahttps://kestrel.arbutus.cloud/grafana

After the switch the legacy cluster has no public name, and your kestrel context stops answering until the rename. Use kestrel-new during that time.

A few other things differ on the new cluster:

  • Your hostnames keep serving from the legacy cluster until they move.
  • Platform certificates for *.<tenant>.kestrel.arbutus.cloud (TLS) don’t issue on the new cluster until the rename, so copy them. They keep renewing on the legacy cluster.
  • Your own Issuers for custom domains work on both clusters.
  • The outbound (NAT) address is different: the new cluster connects from 206.12.102.48. If a remote service allowlists Kestrel, add this address alongside the current one before you cut over.

Don’t publish a site under *.<tenant>.kestrel-prod.arbutus.cloud. That name is temporary, and those certificates stop renewing at the rename.

Skip this section unless you point a domain you control at Kestrel. You don’t need to change anything before you migrate.

  • A CNAME to kestrel.arbutus.cloud, or a CDN or proxy such as Cloudflare whose origin is that name: leave it. It moves to the new cluster at the switch. To move at a different time, see Cut over.
  • An origin that is an IP address: this doesn’t follow the switch. Ask RCS for the new address, and change it when you cut over.

Prepare while the legacy cluster keeps serving, then cut over at a time you agree with RCS. Repeat for each namespace.

Keep your kestrel context. Your kestrel-oidc user from Install kubelogin works on both clusters:

Terminal window
kubectl config set-cluster kestrel-new --server=https://proxy.kestrel-prod.arbutus.cloud
kubectl config set-context kestrel-new --cluster=kestrel-new --user=kestrel-oidc
kubectl --context kestrel-new get ns

Use the same names as on the legacy cluster. SealedSecrets decrypt only in the namespace they were sealed for, and Middleware references and Issuers carry their namespace. ArgoCD’s CreateNamespace=true creates them for you.

Two kinds of certificate can’t issue on the new cluster yet: an HTTP01 Issuer can’t validate until your domain points there, and platform certificates for tenant hostnames wait for the rename. Copy the certificate’s Secret before you deploy the Ingress that uses it, so the new cluster serves it from the first request. cert-manager renews it there afterwards. Do the same for a certificate you created by hand.

Terminal window
kubectl --context kestrel get secret myapp-tls -n <tenant>-prod -o json \
| jq 'del(.metadata.uid, .metadata.resourceVersion, .metadata.creationTimestamp, .metadata.managedFields, .metadata.ownerReferences)' \
| kubectl --context kestrel-new create -f -

A DNS01 Issuer for your own domain issues on the new cluster straight away, so it needs no copy.

Deploy to the new cluster the way you deploy today:

  • ArgoCD: RCS copies no Applications or repository credentials. Recreate those you made in the ArgoCD UI at https://kestrel-prod.arbutus.cloud/argocd, re-add private repository credentials, and kubectl apply any Applications you keep as YAML.
  • Helm or kubectl: run the same commands against the kestrel-new context.
  • SealedSecrets: they decrypt unchanged. Seal new ones against the new cluster by re-fetching the certificate with your kestrel-new context.

Until cutover, keep stopped anything that writes data, or that writes to anything both clusters reach: CronJobs, Jobs, and workloads that write to a database, a share, or an external service. Both clusters’ ArgoCD deploy whatever your Git source says, so give the new cluster’s Application a source where those workloads have replicas: 0 and CronJobs suspend: true: a branch, a Kustomize overlay, or Helm values set on the Application.

Volumes (csi-cinder-sc-*) belong to the old cloud and can’t be attached to the new cluster. Copy them through a CephFS share in your Arbutus project, which both clusters can mount:

  1. Create the share and an access rule, and set its ownership: steps 1–3 of CephFS shares.

  2. Create the share’s Secret and claim (steps 4–5) in the namespace on both clusters, with --context kestrel and --context kestrel-new.

  3. On the legacy cluster, copy the volume into the share. The volume is ReadWriteOnce, so stop the workload that mounts it first; otherwise the Job waits with a Multi-Attach error.

    apiVersion: batch/v1
    kind: Job
    metadata:
    name: copy-my-data
    namespace: <tenant>-prod
    spec:
    template:
    spec:
    restartPolicy: OnFailure
    securityContext:
    runAsNonRoot: true
    runAsUser: 1000 # the user your workload runs as, so every file is readable
    runAsGroup: 1000
    seccompProfile:
    type: RuntimeDefault
    containers:
    - name: copy
    image: busybox:1.37
    command: ["sh", "-c", "mkdir -p /to/my-data && tar -C /from -cf - . | tar -C /to/my-data -xf -"]
    securityContext:
    allowPrivilegeEscalation: false
    capabilities:
    drop: [ALL]
    volumeMounts:
    - { name: from, mountPath: /from, readOnly: true }
    - { name: to, mountPath: /to }
    volumes:
    - name: from
    persistentVolumeClaim:
    claimName: my-data # your volume
    - name: to
    persistentVolumeClaim:
    claimName: migration-share # the share's claim
  4. On the new cluster, mount the share in your workload directly, or copy back into a new volume with the same Job: swap the claims, use /from/my-data as the source, and add fsGroup: 1000 so the fresh volume is writable (Moving data).

  5. When you’re done, delete the claims on both clusters. The share keeps its data until you delete it in OpenStack.

Databases: dump and restore instead of copying files. For PostgreSQL, a pipe between the two contexts:

Terminal window
kubectl --context kestrel exec -n <tenant>-prod <postgres-pod> -- pg_dump -Fc -U <user> <db> \
| kubectl --context kestrel-new exec -i -n <tenant>-prod <postgres-pod> -- pg_restore -U <user> -d <db> --clean --if-exists

Shared volumes RCS arranged for you already exist on the new cluster and reach the same storage, so there is nothing to copy. Never run writers on both clusters at once.

Your hostnames still reach the legacy cluster. Send a request to the new cluster directly:

Terminal window
curl --resolve myapp.<tenant>.kestrel.arbutus.cloud:443:$(dig +short kestrel-prod.arbutus.cloud | tail -n1) \
https://myapp.<tenant>.kestrel.arbutus.cloud/

This works for custom domains too, once you’ve copied their certificate.

Email RCS with your tenant, the hostnames to move, and a time. At that time:

  1. Stop the writers on the legacy cluster. With ArgoCD, point the legacy Application at your stopped source, or pause auto-sync and scale to zero; otherwise selfHeal undoes kubectl scale. With Helm or kubectl, scale to zero and suspend CronJobs.
  2. Copy your data a final time, or dump and restore again.
  3. Start the writers on the new cluster by switching its Application to your normal source.
  4. Move DNS, which depends on the name:
    • Tenant hostnames: RCS repoints them to the new cluster.
    • A custom domain or CDN origin that points at kestrel.arbutus.cloud: this moves at the switch, so the simplest choice is to agree with RCS that you’ll cut over then. To cut over sooner, repoint it to kestrel-prod.arbutus.cloud yourself, then back to kestrel.arbutus.cloud any time after the switch, when both names reach the new cluster.
    • A CDN origin that is an IP address: change it to the address RCS gave you.
  5. Check with plain curl once DNS has moved.

Leave the legacy cluster scaled to zero until shutdown; it is your rollback.

Before the switch: stop the writers on the new cluster, start them on the legacy cluster with your kestrel context, and email RCS to point your hostnames back. Point a custom domain you repointed back to kestrel.arbutus.cloud yourself. Data written on the new cluster after cutover isn’t on the legacy cluster; copy it back the same way if you need it.

After the switch: the legacy cluster has no public name, so email RCS first, and we’ll tell you how to reach it.

RCS announces the time. ArgoCD, Grafana and kubectl on the new cluster move to kestrel.arbutus.cloud, and the kestrel-prod addresses stop answering. Your sites aren’t affected. Your original kestrel context reaches the new cluster, so remove the temporary one:

Terminal window
kubectl config delete-context kestrel-new
kubectl config delete-cluster kestrel-new

RCS deletes the legacy cluster with every volume, Secret and Application on it, and keeps no copies. Anything you haven’t moved by then is gone.