Miscellaneous fixes for autopilot

These changes are only for the autopilot test harness.
They add hidden commands and keystrokes but don't affect
the content of the slides.
This commit is contained in:
Jerome Petazzoni
2018-08-20 14:15:06 -05:00
parent 54288502a2
commit 62686d0b7a
8 changed files with 83 additions and 10 deletions

View File

@@ -189,7 +189,8 @@ done
```bash
if which kubectl; then
kubectl get all -o name | grep -v service/kubernetes | xargs -rn1 kubectl delete
kubectl get deploy,ds -o name | xargs -rn1 kubectl delete
kubectl get all -o name | grep -v service/kubernetes | xargs -rn1 kubectl delete --ignore-not-found=true
fi
```
-->

View File

@@ -95,10 +95,21 @@ Note: `--export` will remove "cluster-specific" information, i.e.:
- Change `kind: Deployment` to `kind: DaemonSet`
<!--
```bash vim rng.yml```
```wait kind: Deployment```
```keys /Deployment```
```keys ^J```
```keys cwDaemonSet```
```keys ^[``` ]
```keys :wq```
```keys ^J```
-->
- Save, quit
- Try to create our new resource:
```bash
```
kubectl apply -f rng.yml
```
@@ -420,11 +431,35 @@ Of course, option 2 offers more learning opportunities. Right?
kubectl edit daemonset rng
```
<!--
```wait Please edit the object below```
```keys /run: rng```
```keys ^J```
```keys noisactive: "yes"```
```keys ^[``` ]
```keys /run: rng```
```keys ^J```
```keys oisactive: "yes"```
```keys ^[``` ]
```keys :wq```
```keys ^J```
-->
- Update the service to add `isactive: "yes"` to its selector:
```bash
kubectl edit service rng
```
<!--
```wait Please edit the object below```
```keys /run: rng```
```keys ^J```
```keys noisactive: "yes"```
```keys ^[``` ]
```keys :wq```
```keys ^J```
-->
]
---

View File

@@ -161,7 +161,7 @@ The dashboard will then ask you which authentication you want to use.
.exercise[
- Edit the service:
```bash
```
kubectl edit service kubernetes-dashboard
```
@@ -192,6 +192,16 @@ The dashboard will then ask you which authentication you want to use.
- Change `ClusterIP` to `NodePort`, save, and exit
<!--
```wait Please edit the object below```
```keys /ClusterIP```
```keys ^J```
```keys cwNodePort```
```keys ^[ ``` ]
```keys :wq```
```keys ^J```
-->
- Check the port that was assigned with `kubectl -n kube-system get services`
- Connect to https://oneofournodes:3xxxx/ (yes, https)

View File

@@ -69,7 +69,10 @@ The `LoadBalancer` type is currently only available on AWS, Azure, and GCE.
kubectl get pods -w
```
<!-- ```keys ^C``` -->
<!--
```wait elastic-```
```keys ^C```
-->
]
@@ -128,6 +131,8 @@ Note: please DO NOT call the service `search`. It would collide with the TLD.
IP=$(kubectl get svc elastic -o go-template --template '{{ .spec.clusterIP }}')
```
<!-- ```hide kubectl wait deploy elastic --for condition=available``` -->
- Send a few requests:
```bash
curl http://$IP:9200/

View File

@@ -198,10 +198,13 @@ We could! But the *deployment* would notice it right away, and scale back to the
<!--
```wait Running```
```keys ^C```
```hide kubectl wait deploy pingpong --for condition=available```
```keys kubectl delete pod ping```
```copypaste pong-..........-.....```
-->
- Destroy a pod:
```bash
```
kubectl delete pod pingpong-xxxxxxxxxx-yyyyy
```
]

View File

@@ -10,7 +10,12 @@
kubectl get deployments -w
```
<!-- ```keys ^C``` -->
<!--
```wait RESTARTS```
```keys ^C```
```wait AVAILABLE```
```keys ^C```
-->
- Now, create more `worker` replicas:
```bash

View File

@@ -114,6 +114,8 @@ In this part, we will:
.exercise[
<!-- ```hide kubectl wait deploy/registry --for condition=available```-->
- View the repositories currently held in our registry:
```bash
curl $REGISTRY/v2/_catalog
@@ -275,6 +277,11 @@ class: extra-details
.exercise[
<!-- ```hide
kubectl wait deploy/rng --for condition=available
kubectl wait deploy/worker --for condition=available
``` -->
- Look at some logs:
```bash
kubectl logs deploy/rng
@@ -328,9 +335,8 @@ class: extra-details
(Give it about 10 seconds to recover)
<!--
```keys
^C
```
```wait units of work done, updating hash counter```
```keys ^C```
-->
]

View File

@@ -96,7 +96,10 @@
kubectl get deployments -w
```
<!-- ```keys ^C``` -->
<!--
```wait NAME```
```keys ^C```
-->
- Update `worker` either with `kubectl edit`, or by running:
```bash
@@ -150,6 +153,11 @@ That rollout should be pretty quick. What shows in the web UI?
kubectl rollout status deploy worker
```
<!--
```wait Waiting for deployment```
```keys ^C```
-->
]
--