authelia/internal/suites/example/compose/kind/patch-kubeconfig.sh

6 lines
348 B
Bash
Executable File

#!/bin/sh
# This script patches the kubeconfig generated by Kind in order to access the cluster container via this container
echo "Patching Kubeconfig to target Kube container without link"
sed -i "s/127.0.0.1:.*/$(docker inspect -f '{{(index .NetworkSettings.Networks "authelia_authelianet").IPAddress}}' kind-control-plane):6443/" ${KUBECONFIG}