forked from gothinkster/golang-gin-realworld-example-app
-
Notifications
You must be signed in to change notification settings - Fork 31
/
Copy pathing.yaml
100 lines (100 loc) · 1.95 KB
/
ing.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
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
annotations:
kubernetes.io/ingress.class: nginx
nginx.ingress.kubernetes.io/rewrite-target: "/"
nginx.ingress.kubernetes.io/custom-http-errors: "404"
nginx.ingress.kubernetes.io/default-backend: custom-error-page
labels:
app: default-http-backend
name: default-http-backend
spec:
rules:
- host:
http:
paths:
- path: "/"
backend:
serviceName: default-http-backend
servicePort: 80
---
apiVersion: v1
kind: Service
metadata:
name: default-http-backend
labels:
app: default-http-backend
spec:
type: NodePort
ports:
- port: 80
targetPort: 80
protocol: TCP
name: http
selector:
app: default-http-backend
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: default-http-backend
labels:
app: default-http-backend
spec:
replicas: 1
selector:
matchLabels:
app: default-http-backend
template:
metadata:
labels:
app: default-http-backend
spec:
containers:
- name: default-http-backend
image: nginx
imagePullPolicy: Always
ports:
- name: http
containerPort: 80
---
apiVersion: v1
kind: Service
metadata:
name: custom-error-page
labels:
app: custom-error-page
spec:
type: NodePort
ports:
- port: 80
targetPort: 8080
protocol: TCP
name: http
selector:
app: custom-error-page
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: custom-error-page
labels:
app: custom-error-page
spec:
replicas: 1
selector:
matchLabels:
app: custom-error-page
template:
metadata:
labels:
app: custom-error-page
spec:
containers:
- name: custom-error-page
image: brndnmtthws/nginx-echo-headers
imagePullPolicy: Always
ports:
- name: http
containerPort: 8080