Free CKA Exam Braindumps (page: 8)

Page 7 of 31

Delete the pod without any delay (force delete)

  1. Solution:
    Kubect1 delete po "POD-NAME" --grace-period=0 ­force

Answer(s): A



Create a redis pod and expose it on port 6379

  1. Solution:

    kubectl run redis --image=redis --restart=Never --port=6379 YAML File :
    apiVersion: v1
    kind: Pod
    metadata:
    labels:
    run: redis
    name: redis
    spec:
    containers:
    - image: redis
    name: redis
    ports:
    - containerPort: 6379
    Rt restartPolicy: Always

Answer(s): A



Create the nginx pod with version 1.17.4 and expose it on port 80

  1. Solution:

    kubectl run nginx --image=nginx:1.17.4 --restart=Never -- port=80

Answer(s): A



Change the Image version to 1.15-alpine for the pod you just created and verify the image version is updated.

  1. Solution:


    Kubect1 set image pod/nginx nginx=nginx:1.15-alpine
    kubect1 describe po nginx
    // another way it will open vi editor and change the version kubeclt edit po nginx
    kubect1 describe po nginx

Answer(s): A






Post your Comments and Discuss Linux Foundation CKA exam with other Community members: