Kubernetes Level1 practice - limits, requests resources Marked Wrong

Question:
Create a pod named httpd-pod and a container under it named as httpd-container, use httpd image with latest tag only and remember to mention tag i.e httpd:latest and set the following limits:
Requests: Memory: 15Mi, CPU: 100m
Limits: Memory: 20Mi, CPU: 100m
Note: The kubectl utility on jump_host has been configured to work with the kubernetes cluster.

pod.yaml
apiVersion: v1
kind: Pod
metadata:
name: httpd-pod
spec:
containers:

  • name: httpd-container
    image: httpd:latest
    resources:
    requests:
    memory: “15Mi”
    cpu: “100m”
    limits:
    memory: “20Mi”
    cpu: “100m”

Indentation gets messed up while writing this in markdown. This is not getting accepted as a correct solution. Can anyone point out the mistake?

Hi @aman3105,
What is the failed message you are getting after submitting? Can you please share?

Regards,

You can use code block feature.

I think you forgot to label this pod.
You should do something like this:

apiVersion: v1
kind: Pod
metadata:
  name: httpd-pod
  labels:
    httpd: latest
spec:
  containers:
    - image: httpd:latest
      name: httpd-container
      resources:
        requests:
          memory: "15Mi"
          cpu: "100m"
        limits:
          memory: "20Mi"
          cpu: "100m"

Thank you! Will keep that in mind.

It worked on the second attempt. It looks like there was a bit of a lag (more than expected) for container creation.

Great!!

Can you please record this through the feedback tool? I will investigate this. @aman3105

Regards,