Added hpa to webspa
This commit is contained in:
parent
42abcad37e
commit
110e4180f5
30
deploy/k8s/helm/webspa/templates/hpa.yaml
Normal file
30
deploy/k8s/helm/webspa/templates/hpa.yaml
Normal file
@ -0,0 +1,30 @@
|
||||
apiVersion: autoscaling/v1
|
||||
kind: HorizontalPodAutoscaler
|
||||
metadata:
|
||||
name: {{ template "webspa.fullname" . }}
|
||||
labels:
|
||||
ufo: {{ $cfgname}}
|
||||
app: {{ template "webspa.name" . }}
|
||||
chart: {{ template "webspa.chart" . }}
|
||||
release: {{ .Release.Name }}
|
||||
heritage: {{ .Release.Service }}
|
||||
spec:
|
||||
scaleTargetRef:
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
name: {{ template "webspa.fullname" . }}
|
||||
minReplicas: 3
|
||||
maxReplicas: 10
|
||||
metrics:
|
||||
- type: Resource
|
||||
resource:
|
||||
name: cpu
|
||||
target:
|
||||
type: Utilization
|
||||
averageUtilization: 50
|
||||
- type: Resource
|
||||
resource:
|
||||
name: memory
|
||||
target:
|
||||
type: Utilization
|
||||
averageUtilization: 50
|
Loading…
x
Reference in New Issue
Block a user