Requirements:
- Rancher Manager kubeconfig
kubectlon client machine- Rancher Token
This patch will be applied to the management cluster.
Set:
export RANCHER_API_URL="https://rancher.tld/" # Do not set /v1 or /v3 URI here
export RANCHER_ACCESS_KEY="token-xxxx"
export RANCHER_SECRET_KEY="xxxxx"
which will be used to locate the cluster ID.
Set export KUBECONFIG to the local cluster (Rancher Manager) kubeconfig which will apply the patch, and using the cluster's UI friendly name:
./enable_jwt.sh cluster-nameto create a new config.
For existing configs, where it was previously created:
./patch_jwt.sh cluster-nameand if successfully enabled, you will see a confirmation prompt:
clusterproxyconfig status for jwt (c-m-tsjkrjq6):
"enabled": true,