Skip to content

Instantly share code, notes, and snippets.

@joshuahendinata
Created September 25, 2019 08:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save joshuahendinata/15ea9c2f48d0e7c78b7f20424d2c4a07 to your computer and use it in GitHub Desktop.
Save joshuahendinata/15ea9c2f48d0e7c78b7f20424d2c4a07 to your computer and use it in GitHub Desktop.
apiVersion: autoscaling/v2beta1
kind: HorizontalPodAutoscaler
metadata:
name: airflow-worker
namespace: # use ${AIRFLOW_WORKER_NS} variable defined above
spec:
scaleTargetRef:
apiVersion: apps/v1
kind: Deployment
name: airflow-worker
minReplicas: 1
maxReplicas: 50 # Adjust this based on your use case
metrics: # Adjust this based on your use case
- type: Resource
resource:
name: memory
targetAverageValue: 1.5Gi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment