-
Notifications
You must be signed in to change notification settings - Fork 0
/
k8s-deployment.yaml
65 lines (64 loc) · 1.54 KB
/
k8s-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
apiVersion: apps/v1
kind: Deployment
metadata:
name: elasticsearch-proxy-api-server
namespace: <NAMESPACE>
spec:
replicas: <NUM_REPLICAS>
selector:
matchLabels:
app: elasticsearch-proxy-api
template:
metadata:
labels:
app: elasticsearch-proxy-api
spec:
containers:
- name: elasticsearch-proxy-api
image: <SERVER_IMAGE_TAG>
imagePullPolicy: Always
resources:
limits:
cpu: <CPU_LIMIT>
requests:
cpu: <CPU_REQUESTED>
volumeMounts:
- name: run-config
mountPath: '/etc/run_config/'
readOnly: true
- name: gunicorn-config
mountPath: '/etc/gunicorn_config/'
readOnly: true
env:
- name: HTTP_PROXY
value: "<HTTP_PROXY>"
- name: http_proxy
value: "<HTTP_PROXY>"
- name: HTTPS_PROXY
value: "<HTTPS_PROXY>"
- name: https_proxy
value: "<HTTPS_PROXY>"
- name: NO_PROXY
value: "<NO_PROXY>"
- name: no_proxy
value: "<NO_PROXY>"
volumes:
- name: run-config
secret:
secretName: <RUN_CONFIG_SECRET_NAME>
- name: gunicorn-config
secret:
secretName: <GUNICORN_CONFIG_SECRET_NAME>
---
apiVersion: v1
kind: Service
metadata:
name: elasticsearch-proxy-api
namespace: <NAMESPACE>
spec:
type: NodePort
selector:
app: elasticsearch-proxy-api
ports:
- port: 5000
targetPort: 5000