Skip to main content
This article explains how to scale applications in OpenShift and Kubernetes. A Deployment is the common higher-level controller used to manage application replicas. A Deployment creates and manages a ReplicaSet (and previously a ReplicationController) which ensures the desired number of Pod replicas exist. To scale an application, you change the desired replica count in the controller’s spec; the ReplicaSet will then create or remove Pods to match that target. Key concepts:
  • Deployment: declarative controller that manages ReplicaSets and rolling updates.
  • ReplicaSet: ensures a specific number of Pod replicas run.
  • Service / Router: distributes traffic to Pods (internal via Service, external via OpenShift Router).
You can change the replica count in several common ways:
  • Edit the Deployment YAML and update spec.replicas.
  • Use command-line shortcuts such as oc scale or kubectl scale.
  • Use the OpenShift web console for one-click scaling.
  • Configure automatic scaling with a Horizontal Pod Autoscaler (HPA) to scale based on CPU, memory, or custom metrics.
A slide titled "Scale Deployment" showing a diagram of a deployment/replication controller with stacked pod/container icons on the left and, on the right, a webapp dashboard for a "simple-webapp" deployment displaying details and a circle indicating 5 pods.
Practical examples
  • Example Deployment YAML (relevant parts shown):
  • Scale from the command line:
  • Query the current state:
  • Enable automatic scaling with a Horizontal Pod Autoscaler (HPA):
Summary table — scaling methods Links and references
Using the OpenShift web console is the quickest way for interactive scaling. For reproducible automation and CI/CD, prefer oc/kubectl commands or defining an HPA in YAML and managing it via GitOps.
Before scaling up, verify your project/cluster has sufficient resource quotas (CPU, memory) and available nodes. When scaling down, be careful with stateful workloads—Pods may be terminated. Use PodDisruptionBudgets and safe shutdown procedures for stateful applications.
Now let’s take a look at a demo.

Watch Video