From 599483eaabf57abadf247aa732071d96d62762fe Mon Sep 17 00:00:00 2001 From: Guang Ya Liu Date: Mon, 24 May 2021 14:22:25 +0800 Subject: [PATCH] updated how to connect to cluster --- docs/README.md | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/docs/README.md b/docs/README.md index 27bc98a9..6360811a 100644 --- a/docs/README.md +++ b/docs/README.md @@ -93,13 +93,11 @@ kubectl port-forward svc/cluster-sample-apiserver 6443:6443 ### Connect to Cluster To use the `KUBECONFIG` created by `clusterctl` without modification, we first -need to setup a host record for the apiserver service name, to do this we can -define a custom hosts file by setting the `HOSTALIASES` env and append the -IP-address-to-URL mapping to the hosts file. +need to setup a host record for the apiserver service name, to do this need add +following line to `/etc/hosts`. -```shell -echo '127.0.0.1 cluster-sample-apiserver' >> ~/.hosts -export HOSTALIASES=~/.hosts +``` +127.0.0.1 cluster-sample-apiserver ``` ### Connect to the Cluster! :tada: