This repository has been archived by the owner on Sep 22, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathngsa-memory.yaml
112 lines (109 loc) · 2.55 KB
/
ngsa-memory.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
103
104
105
106
107
108
109
110
111
112
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{gitops.name}}-memory
namespace: {{gitops.namespace}}
labels:
app.kubernetes.io/name: {{gitops.name}}-memory
spec:
replicas: 1
strategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 1
maxUnavailable: 0
selector:
matchLabels:
app: {{gitops.name}}-memory
template:
metadata:
labels:
app: {{gitops.name}}-memory
version: beta-{{gitops.version}}
deploy: {{gitops.deploy}}
spec:
containers:
- name: app
image: {{gitops.imageName}}:{{gitops.imageTag}}
imagePullPolicy: Always
args:
- --in-memory
- --prometheus
- --zone
- {{gitops.config.zone}}
- --region
- {{gitops.config.region}}
ports:
- name: http
containerPort: 8080
protocol: TCP
readinessProbe:
initialDelaySeconds: 5
httpGet:
path: /version
port: 8080
livenessProbe:
initialDelaySeconds: 60
periodSeconds: 300
httpGet:
path: /healthz
port: 8080
resources:
limits:
cpu: 1000m
memory: 512Mi
requests:
cpu: 50m
memory: 128Mi
securityContext:
readOnlyRootFilesystem: true
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
runAsNonRoot: true
runAsUser: 10001
volumeMounts:
- mountPath: /tmp
name: tmp
volumes:
- emptyDir: {}
name: tmp
automountServiceAccountToken: false
securityContext:
seccompProfile:
type: RuntimeDefault
nodeSelector:
kubernetes.azure.com/mode: user
---
apiVersion: v1
kind: Service
metadata:
name: {{gitops.name}}-memory
namespace: {{gitops.namespace}}
spec:
type: ClusterIP
ports:
- port: 8080
targetPort: http
protocol: TCP
name: http
selector:
app: {{gitops.name}}-memory
---
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: {{gitops.name}}-memory-vs
namespace: {{gitops.namespace}}
spec:
gateways:
- istio-system/istio-gateway
hosts:
- {{gitops.name}}-memory-{{gitops.config.region}}-dev.{{gitops.config.domain}}
http:
- route:
- destination:
port:
number: 8080
host: {{gitops.name}}-memory