forked from fonoster/routr
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathroutr.yml
67 lines (67 loc) · 1.45 KB
/
routr.yml
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
apiVersion: v1
kind: Service
metadata:
name: routr
labels:
app: routr
spec:
type: NodePort
externalTrafficPolicy: Local # This will cause the load balancer to send the client ip
externalIPs:
- 192.168.1.127
ports:
- name: sip
port: 5060
- name: https
port: 4567
selector:
app: routr
tier: sip
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: routr
labels:
app: routr
spec:
strategy:
type: Recreate
template:
metadata:
labels:
app: routr
tier: sip
spec:
containers:
- name: routr
image: fonoster/routr
imagePullPolicy: Always
command: ["/bin/sh"]
args: ["-c", "sh /opt/routr/entrypoint.sh"]
env:
- name: ROUTR_DS_PROVIDER
value: redis_data_provider
- name: ROUTR_DS_PARAMETERS
value: 'host=redis,port=6379'
- name: ROUTR_EXTERN_ADDR
value: '192.168.1.127'
ports:
- containerPort: 5060
name: sip
- containerPort: 4567
name: https
volumeMounts:
- name: entrypoint
mountPath: /opt/routr/entrypoint.sh
subPath: entrypoint.sh
- name: bootstrap
mountPath: /opt/routr/bootstrap.yml
subPath: bootstrap.yml
volumes:
- name: entrypoint
configMap:
name: entrypoint
- name: bootstrap
configMap:
name: bootstrap