I think the grading for lab3 has an issue. It says my beta command is wrong. I a . . .

Stanislaus Tebid:
I think the grading for lab3 has an issue. It says my beta command is wrong. I asked the container to sleep for 4800 second and this seems fine to me.,

apiVersion: v1
kind: Pod
metadata:
  creationTimestamp: null
  labels:
    run: multi-pod
  name: multi-pod
spec:
  containers:
  - args:
    - sleep
    - "4800"
    image: nginx
    name: beta
    env:
    - name: name
      value: beta
  - name: alpha
    image: nginx
    env:
    - name: name
      value: alpha
  dnsPolicy: ClusterFirst
  restartPolicy: Always
status: {}
~                                                                                                                                   
~                

Chris:
@Stanislaus Tebid
Not sure, but try to nest it the other way around.
See below. Sorry on my phone so I wouldn’t copy this.

containers:
  - name: something 
    image: nginx
    command:
       - sleep
       - “4800”

Alistair Mackay:
Correct @Chris

Needs to be command here such that the container’s default command is substituted with a new command.

Using args will pass arguments to the default command for the container, which in this case is nginx so it would run

nginx sleep 4800

which nginx would either ignore and the container would run, or take exception to and the container would go to CrashLoopBackOff

unnivkn:
HI @Stanislaus Tebid you may try this:
image.png
image.png