-
Notifications
You must be signed in to change notification settings - Fork 0
/
Kubernets.yaml
72 lines (69 loc) · 1.14 KB
/
Kubernets.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
apiVersion: apps/v1
kind: Deployment
metadata:
name: system-deployment
labels:
app: system
spec:
selector:
matchLabels:
app: system
template:
metadata:
labels:
app: system
spec:
containers:
- name: system-container
image: system:1.0-SNAPSHOT
ports:
- containerPort: 9080
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: inventory-deployment
labels:
app: inventory
spec:
selector:
matchLabels:
app: inventory
template:
metadata:
labels:
app: inventory
spec:
containers:
- name: inventory-container
image: inventory:1.0-SNAPSHOT
ports:
- containerPort: 9080
---
apiVersion: v1
kind: Service
metadata:
name: system-service
spec:
type: NodePort
selector:
app: system
ports:
- protocol: TCP
port: 9080
targetPort: 9080
nodePort: 31000
---
apiVersion: v1
kind: Service
metadata:
name: inventory-service
spec:
type: NodePort
selector:
app: inventory
ports:
- protocol: TCP
port: 9080
targetPort: 9080
nodePort: 32000