kubernetes command line to scale down pods 1

kubernetes command line to scale down pods

kubectl scale --replicas=4 deployment my-nginxdeployment

Here is what the above code is Doing:
1. We are creating a deployment named my-nginxdeployment.
2. We are using the nginx image from Docker Hub.
3. We are telling the deployment to run 2 replicas of the nginx container.
4. We are exposing port 80 on the container to port 8080 on the host.
5. We are telling the deployment to run 2 replicas of the nginx container.
6. We are telling the deployment to run 4 replicas of the nginx container.

Similar Posts