commit
d89948a59a
40
deploy/azure/autoscaling.yml
Normal file
40
deploy/azure/autoscaling.yml
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
---
|
||||||
|
apiVersion: autoscaling/v2beta1
|
||||||
|
kind: HorizontalPodAutoscaler
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: atst
|
||||||
|
name: atst
|
||||||
|
namespace: atat
|
||||||
|
spec:
|
||||||
|
minReplicas: 2
|
||||||
|
maxReplicas: 10
|
||||||
|
scaleTargetRef:
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
name: atst
|
||||||
|
metrics:
|
||||||
|
- type: Resource
|
||||||
|
resource:
|
||||||
|
name: cpu
|
||||||
|
targetAverageUtilization: 60
|
||||||
|
---
|
||||||
|
apiVersion: autoscaling/v2beta1
|
||||||
|
kind: HorizontalPodAutoscaler
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: atst
|
||||||
|
name: atst-worker
|
||||||
|
namespace: atat
|
||||||
|
spec:
|
||||||
|
minReplicas: 1
|
||||||
|
maxReplicas: 10
|
||||||
|
scaleTargetRef:
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
name: atst-worker
|
||||||
|
metrics:
|
||||||
|
- type: Resource
|
||||||
|
resource:
|
||||||
|
name: cpu
|
||||||
|
targetAverageUtilization: 60
|
@ -15,7 +15,6 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
role: web
|
role: web
|
||||||
replicas: 4
|
|
||||||
strategy:
|
strategy:
|
||||||
type: RollingUpdate
|
type: RollingUpdate
|
||||||
template:
|
template:
|
||||||
@ -169,7 +168,6 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
role: worker
|
role: worker
|
||||||
replicas: 2
|
|
||||||
strategy:
|
strategy:
|
||||||
type: RollingUpdate
|
type: RollingUpdate
|
||||||
template:
|
template:
|
||||||
@ -207,10 +205,10 @@ spec:
|
|||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
memory: 280Mi
|
memory: 280Mi
|
||||||
cpu: 20m
|
cpu: 400m
|
||||||
limits:
|
limits:
|
||||||
memory: 280Mi
|
memory: 280Mi
|
||||||
cpu: 20m
|
cpu: 400m
|
||||||
volumes:
|
volumes:
|
||||||
- name: pgsslrootcert
|
- name: pgsslrootcert
|
||||||
configMap:
|
configMap:
|
||||||
|
@ -12,3 +12,4 @@ resources:
|
|||||||
- acme-challenges.yml
|
- acme-challenges.yml
|
||||||
- aadpodidentity.yml
|
- aadpodidentity.yml
|
||||||
- nginx-snippets.yml
|
- nginx-snippets.yml
|
||||||
|
- autoscaling.yml
|
||||||
|
@ -5,7 +5,6 @@ resources:
|
|||||||
- namespace.yml
|
- namespace.yml
|
||||||
- reset-cron-job.yml
|
- reset-cron-job.yml
|
||||||
patchesStrategicMerge:
|
patchesStrategicMerge:
|
||||||
- replica_count.yml
|
|
||||||
- ports.yml
|
- ports.yml
|
||||||
- envvars.yml
|
- envvars.yml
|
||||||
- flex_vol.yml
|
- flex_vol.yml
|
||||||
|
@ -1,14 +0,0 @@
|
|||||||
---
|
|
||||||
apiVersion: extensions/v1beta1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: atst
|
|
||||||
spec:
|
|
||||||
replicas: 2
|
|
||||||
---
|
|
||||||
apiVersion: extensions/v1beta1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: atst-worker
|
|
||||||
spec:
|
|
||||||
replicas: 1
|
|
@ -5,7 +5,6 @@ resources:
|
|||||||
- namespace.yml
|
- namespace.yml
|
||||||
- reset-cron-job.yml
|
- reset-cron-job.yml
|
||||||
patchesStrategicMerge:
|
patchesStrategicMerge:
|
||||||
- replica_count.yml
|
|
||||||
- ports.yml
|
- ports.yml
|
||||||
- envvars.yml
|
- envvars.yml
|
||||||
- flex_vol.yml
|
- flex_vol.yml
|
||||||
|
@ -1,14 +0,0 @@
|
|||||||
---
|
|
||||||
apiVersion: extensions/v1beta1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: atst
|
|
||||||
spec:
|
|
||||||
replicas: 2
|
|
||||||
---
|
|
||||||
apiVersion: extensions/v1beta1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: atst-worker
|
|
||||||
spec:
|
|
||||||
replicas: 1
|
|
Loading…
x
Reference in New Issue
Block a user