Update 'kubectl create deployment' for 1.19

This commit is contained in:
Jerome Petazzoni
2020-09-02 16:48:19 +02:00
parent d98fcbce87
commit fee0be7f09
2 changed files with 14 additions and 5 deletions

View File

@@ -176,12 +176,8 @@ class: extra-details
- can't express parallelism or completions of Jobs
- can't express Pods with multiple containers
- can't express healthchecks, resource limits
- etc.
- `kubectl create` and `kubectl run` are *helpers* that generate YAML manifests
- If we write these manifests ourselves, we can use all features and options

View File

@@ -296,7 +296,7 @@ class: extra-details
- When using `kubectl create deployment`, we cannot indicate the command to execute
(at least, not in Kubernetes 1.18)
(at least, not in Kubernetes 1.18; but that changed in Kubernetes 1.19)
- We can:
@@ -344,6 +344,19 @@ class: extra-details
---
class: extra-details
## In Kubernetes 1.19
- Since Kubernetes 1.19, we can specify the command to run
- The command must be passed after two dashes:
```bash
kubectl create deployment pingpong --image=alpine -- ping 127.1
```
---
## Viewing container output
- Let's use the `kubectl logs` command