@@ -80,8 +80,10 @@ Our master node makes use of some of the files in this repo so lets securely cop
80
80
81
81
master_ip=$(terraform output -json | jq -r '.master_address.value')
82
82
ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip sudo kubeadm init > k8s-init.log
83
+ ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip "sudo cp /etc/kubernetes/admin.conf /home/ubuntu/"
84
+ ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip "sudo chown \$(id -u):\$(id -g) \$HOME/admin.conf"
83
85
grep -e --token k8s-init.log > join.cmd
84
- ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip kubectl apply -f https://git.io/weave-kube
86
+ ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip KUBECONFIG=\$HOME/admin.conf kubectl apply -f https://git.io/weave-kube-1.6
85
87
86
88
<!-- deploy-doc-end -->
87
89
@@ -107,7 +109,7 @@ There are two options for running Weave Scope, either you can run the UI locally
107
109
<!-- deploy-doc-start create-infrastructure -->
108
110
109
111
master_ip=$(terraform output -json | jq -r '.master_address.value')
110
- ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip kubectl apply -f 'https://cloud.weave.works/launch/k8s/weavescope.yaml'
112
+ ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip KUBECONFIG=\$HOME/admin.conf kubectl apply -f 'https://cloud.weave.works/launch/k8s/weavescope.yaml'
111
113
112
114
<!-- deploy-doc-end -->
113
115
@@ -139,7 +141,7 @@ You may optionally choose to configure Weave Flux which allows automatic deploym
139
141
<!-- deploy-doc-start create-infrastructure -->
140
142
141
143
master_ip=$(terraform output -json | jq -r '.master_address.value')
142
- ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip kubectl apply -f /tmp/manifests/sock-shop-ns.yaml -f /tmp/manifests/zipkin-ns.yaml -f /tmp/manifests
144
+ ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip KUBECONFIG=\$HOME/admin.conf kubectl apply -f /tmp/manifests/sock-shop-ns.yaml -f /tmp/manifests/zipkin-ns.yaml -f /tmp/manifests
143
145
144
146
<!-- deploy-doc-end -->
145
147
@@ -194,7 +196,7 @@ This will send some traffic to the application, which will form the connection g
194
196
docker run --rm weaveworksdemos/load-test -d 300 -h $elb_url -c 2 -r 100
195
197
196
198
master_ip=$(terraform output -json | jq -r '.master_address.value')
197
- ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip "kubectl run -i -t -\-namespace=sock-shop healthcheck -\-restart=Never -\-image=weaveworksdemos/healthcheck:snapshot -- -s orders,carts,payment,user,catalogue,shipping,queue-master -d 60 -r 5"
199
+ ssh -i ~/.ssh/deploy-docs-k8s.pem ubuntu@$master_ip "KUBECONFIG=\$HOME/admin.conf kubectl run -i -t -\-namespace=sock-shop healthcheck -\-restart=Never -\-image=weaveworksdemos/healthcheck:snapshot -- -s orders,carts,payment,user,catalogue,shipping,queue-master -d 60 -r 5"
198
200
199
201
set +e
200
202
0 commit comments