Work on the following -
Get the list of all services across all namespaces and write the output to /root/all-services.txt file.
kubectl get svc -A > path.txt
-A
is short for all the namespaces
Generate a pod manifest file at /root/mypodx.yaml. Pod name should be mypodx with image redis. Make sure you only generate the pod manifest file, you do not have to crete the pod.
k run mypodx --image=redis --restart=Never --dry-run=client -o yaml > /root/mypodx.yaml
Creating configmap and secrets and then using them inside a pod.