-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathk8s-frontend.yml
54 lines (51 loc) · 944 Bytes
/
k8s-frontend.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
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: k8s-study-frontend-ingress
annotations:
nginx.ingress.kubernetes.io/ssl-redirect: "false"
spec:
rules:
- host: pongpong.io
http:
paths:
- backend:
serviceName: k8s-frontend
servicePort: 3000
- host: www.pongpong.io
http:
paths:
- backend:
serviceName: k8s-frontend
servicePort: 3000
---
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: k8s-frontend
spec:
replicas: 1
selector:
matchLabels:
type: frontend
service: k8s-frontend
template:
metadata:
labels:
type: frontend
service: k8s-frontend
spec:
containers:
- name: k8s-frontend
image: subicura/k8s-frontend
---
apiVersion: v1
kind: Service
metadata:
name: k8s-frontend
spec:
ports:
- port: 3000
selector:
type: frontend
service: k8s-frontend