-
Notifications
You must be signed in to change notification settings - Fork 36
/
Copy pathdeployment.yaml
102 lines (102 loc) · 2.76 KB
/
deployment.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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
apiVersion: v1
kind: Namespace
metadata:
name: ack-system
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: ack-sagemaker-controller
namespace: ack-system
labels:
app.kubernetes.io/name: ack-sagemaker-controller
app.kubernetes.io/part-of: ack-system
spec:
selector:
matchLabels:
app.kubernetes.io/name: ack-sagemaker-controller
replicas: 1
template:
metadata:
labels:
app.kubernetes.io/name: ack-sagemaker-controller
spec:
containers:
- command:
- ./bin/controller
args:
- --aws-region
- "$(AWS_REGION)"
- --aws-endpoint-url
- "$(AWS_ENDPOINT_URL)"
- --enable-development-logging=$(ACK_ENABLE_DEVELOPMENT_LOGGING)
- --log-level
- "$(ACK_LOG_LEVEL)"
- --resource-tags
- "$(ACK_RESOURCE_TAGS)"
- --watch-namespace
- "$(ACK_WATCH_NAMESPACE)"
- --enable-leader-election=$(ENABLE_LEADER_ELECTION)
- --leader-election-namespace
- "$(LEADER_ELECTION_NAMESPACE)"
image: controller:latest
name: controller
ports:
- name: http
containerPort: 8080
resources:
limits:
cpu: 100m
memory: 300Mi
requests:
cpu: 100m
memory: 200Mi
env:
- name: ACK_SYSTEM_NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
- name: AWS_REGION
value: ""
- name: AWS_ENDPOINT_URL
value: ""
- name: ACK_WATCH_NAMESPACE
value: ""
- name: ACK_ENABLE_DEVELOPMENT_LOGGING
value: "false"
- name: ACK_LOG_LEVEL
value: "info"
- name: ACK_RESOURCE_TAGS
value: "services.k8s.aws/controller-version=%CONTROLLER_SERVICE%-%CONTROLLER_VERSION%,services.k8s.aws/namespace=%K8S_NAMESPACE%"
- name: ENABLE_LEADER_ELECTION
value: "false"
- name: LEADER_ELECTION_NAMESPACE
value: "ack-system"
securityContext:
allowPrivilegeEscalation: false
privileged: false
runAsNonRoot: true
capabilities:
drop:
- ALL
livenessProbe:
httpGet:
path: /healthz
port: 8081
initialDelaySeconds: 15
periodSeconds: 20
readinessProbe:
httpGet:
path: /readyz
port: 8081
initialDelaySeconds: 5
periodSeconds: 10
securityContext:
seccompProfile:
type: RuntimeDefault
terminationGracePeriodSeconds: 10
serviceAccountName: ack-sagemaker-controller
hostIPC: false
hostPID: false
hostNetwork: false
dnsPolicy: ClusterFirst