CKAD-exercises
CKAD-exercises copied to clipboard
Update e.observability.md
With the double-quotes enclosing : $i: $(date) , it not yielding the logs. Therefore by removing the double quotes it works just fine.
thanks for the review, are you sure it doesn't work as is? Can't repro
dgkanatsios@digkanat:dgkanatsios$ kubectl run busybox --image=busybox --restart=Never -- /bin/sh -c 'i=0; while true; do echo "$i: $(date)"; i=$((i+1)); sleep 1; done'
pod/busybox created
dgkanatsios@digkanat:dgkanatsios$ k logs busybox -f
0: Mon Oct 5 03:05:43 UTC 2020
1: Mon Oct 5 03:05:44 UTC 2020
2: Mon Oct 5 03:05:45 UTC 2020
3: Mon Oct 5 03:05:46 UTC 2020
4: Mon Oct 5 03:05:47 UTC 2020
5: Mon Oct 5 03:05:48 UTC 2020
6: Mon Oct 5 03:05:49 UTC 2020
7: Mon Oct 5 03:05:50 UTC 2020
8: Mon Oct 5 03:05:51 UTC 2020
9: Mon Oct 5 03:05:52 UTC 2020
10: Mon Oct 5 03:05:53 UTC 2020
11: Mon Oct 5 03:05:54 UTC 2020