-
Notifications
You must be signed in to change notification settings - Fork 911
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
karmada kubeconfig server #6048
Comments
someone finally shares my concerns, I used to created a similar issue: #4013 For now, you can handle it this way: #4013 (comment) I also look forward to hearing your solution as well |
is this it for this DNS problem i have got "server misbehaving" ? |
If i want to automate this stage, should i run the karmada join in the cluster. Or should i install karmada using cli ? |
I'm also curious about how others successfully install karmada by # 1. this script try to deploy karmada-apiserver by host-network
# so, it needs to get host-network ip (node ip) from kube-apiserver, and then add this ip to values.yaml as SANs of certificate
export KUBECONFIG=${KARMADA_HOST_KUBECONFIG}
HOST_IP=$(kubectl get ep kubernetes -o jsonpath='{.subsets[0].addresses[0].ip}')
sed -i'' -e "/localhost/{n;s/ \"127.0.0.1/ \"${HOST_IP}\",\n&/g}" ${CHARTDIR}/values.yaml
# 2. install karmada at karmada-host cluster by helm
# pay attention to apiServer.hostNetwork=true
helm install karmada -n karmada-system \
--kubeconfig "${KARMADA_HOST_KUBECONFIG}" \
--create-namespace \
--dependency-update \
--set apiServer.hostNetwork=true,components={"metricsAdapter,search,descheduler"} \
${CHARTDIR}
# 3.verify: wait for karmada control plane ready
while [[ $(kubectl get po -A | grep -c karmada-system ) -ne $(kubectl get po -n karmada-system | grep -c Running) ]]; do
echo "waiting for karmada control plane ready..."; sleep 5;
done
kubectl get po -n karmada-system -o wide
# 4. export kubeconfig of karmada-apiserver to local path and change service name to apiserver ip.
KARMADA_APISERVER_KUBECONFIG="${HOME}/.kube/karmada-apiserver.config"
kubectl get secret -n karmada-system karmada-kubeconfig -o jsonpath={.data.kubeconfig} | base64 -d > "${KARMADA_APISERVER_KUBECONFIG}"
KARMADA_APISERVER_ADDR=$(kubectl get ep karmada-apiserver -n karmada-system | tail -n 1 | awk '{print $2}')
sed -i'' -e "s/karmada-apiserver.karmada-system.svc.*:5443/${KARMADA_APISERVER_ADDR}/g" "${KARMADA_APISERVER_KUBECONFIG}"
Of course, if you choose install karmada by cli or operator, you won't have this problem. |
Hey i deployed karmada in kubernetes using the helm chart with nodeport service.
I'd like as a kubeconfig output the ip of the service not the DNS in the server field.
How can i do that automatically ?
Thanks
The text was updated successfully, but these errors were encountered: