Welcome to the Linux Foundation Forum!

kubectl run command does not seems to generate deployment

In the "Managing State with Deployments" it says :
"The default controller for a container deployed via kubectl run command is a Deployment."
But the kubectl run command generate/deploy Pod object not Deployment :

$ kubectl run nginx --image=nginx --dry-run=client -o yaml
apiVersion: v1
kind: Pod
metadata:
  creationTimestamp: null
  labels:
    run: nginx
  name: nginx
spec:
  containers:
  - image: nginx
    name: nginx
    resources: {}
  dnsPolicy: ClusterFirst
  restartPolicy: Always
status: {}

Answers

Categories

Upcoming Training