clank-bootstrapper/clusterapi/move-cluster.sh

18 lines
388 B
Bash
Raw Normal View History

2022-12-10 22:08:07 +01:00
#!/bin/bash
set -e
. variables.sh
echo "initializing cluster api in management cluster"
export KUBECONFIG=output/workload-kubeconfig
clusterctl init --core cluster-api --bootstrap kubeadm --control-plane kubeadm --infrastructure hetzner
echo "switching back to helm"
export KUBECONFIG=~/.kube/config
clusterctl move --to-kubeconfig $CAPH_WORKER_CLUSTER_KUBECONFIG
echo "move done"