Deploy Pods in Kubernetes Cluster
How to Deploy Pods in a Kubernetes Cluster

Infosec Poet and CAP-certified DevOps/SecOps Engineer, passionate about security, creativity, and continuous learning.
Tasks
Create a pod named
pod-httpdusing thehttpdimage with thelatesttag. Ensure to specify the tag ashttpd:latest.Set the
applabel tohttpd_app, and name the container ashttpd-container.
Steps
Create a pod called
pod-httpdusing thehttpdimage with thelatesttag, ensuring the tag is specified ashttpd:latest.- Create a yaml file
cat > pod-httpd.yaml <<EOF
apiVersion: v1
kind: Pod
metadata:
name: pod-httpd
labels:
app: httpd_app
spec:
containers:
- name: httpd-container
image: httpd:latest
EOF

apiVersion: v1
kind: Pod
metadata:
name: pod-httpd
labels:
app: httpd_app
spec:
containers:
- name: httpd-container
image: httpd:latest
You can apply this configuration with this command.
kubectl apply -f pod-httpd.yaml
To ensure or check the create pods.
kubectl get pods
#k8s #pods #devops





