This repository has been archived by the owner on Jun 8, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 159
/
autoscaler-dep.yaml
82 lines (82 loc) · 2.12 KB
/
autoscaler-dep.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: autoscaler
namespace: kube-system
labels:
k8s-app: autoscaler
spec:
replicas: 1
selector:
matchLabels:
k8s-app: autoscaler
template:
metadata:
labels:
k8s-app: autoscaler
openai/do-not-drain: "true"
# annotations:
# scheduler.alpha.kubernetes.io/tolerations: "[{key: dedicated, value: master}]"
spec:
containers:
- name: autoscaler
image: quay.io/openai/kubernetes-ec2-autoscaler
resources:
limits:
cpu: 500m
memory: 300Mi
requests:
cpu: 100m
memory: 100Mi
env:
- name: CAPACITY_CPU_RESERVE
value: "0.1"
- name: AWS_ACCESS_KEY_ID
valueFrom:
secretKeyRef:
name: autoscaler
key: aws-access-key-id
- name: AWS_SECRET_ACCESS_KEY
valueFrom:
secretKeyRef:
name: autoscaler
key: aws-secret-access-key
- name: SLACK_HOOK
valueFrom:
secretKeyRef:
name: autoscaler
key: slack-hook
- name: SLACK_BOT_TOKEN
valueFrom:
secretKeyRef:
name: autoscaler
key: slack-bot-token
- name: DATADOG_API_KEY
valueFrom:
secretKeyRef:
name: autoscaler
key: datadog-api-key
- name: PYKUBE_KUBERNETES_SERVICE_HOST
value: kubernetes.default
#value: 10.100.0.1
- name: DATADOG_TAGS
value: env:sci
command:
- python
- main.py
- --regions
- us-east-1
- --cluster-name
- pipeline.kubernetes.dev.aws.away.black
- -vvv
- --type-idle-threshold
- "0"
- --over-provision
- "1"
- --sleep
- "30"
imagePullPolicy: Always
restartPolicy: Always
# dnsPolicy: Default # Don't use cluster DNS.
nodeSelector:
kubernetes.io/role: master