In our example we have a deployment with three replicas of the "nginx" pod.
Below is the Yaml file of our deployment:
We create our deployment using the below command:
The "default-priority" assigned to the "nginx"pods is defined as below:
We create our PriorityClass using the "kubectl apply" command.
If for example, we check the events and we notice that our "nginx" pods are running out of resources - maybe consumed by other high-priority pods -, we could increase for our deployment and its three "nginx" replicas the limit of the resources it can use as below: