Skip to content

Commit 75b76ae

Browse files
committed
Updated with preprod dns values
1 parent 1e6da54 commit 75b76ae

File tree

1 file changed

+125
-0
lines changed

1 file changed

+125
-0
lines changed

k8s-preprod/app.yaml

Lines changed: 125 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,125 @@
1+
apiVersion: v1
2+
kind: Namespace
3+
metadata:
4+
name: chime
5+
6+
---
7+
8+
apiVersion: apps/v1
9+
kind: Deployment
10+
metadata:
11+
name: chime
12+
namespace: chime
13+
labels:
14+
app: chime
15+
spec:
16+
replicas: 15
17+
strategy:
18+
type: Recreate
19+
selector:
20+
matchLabels:
21+
app: chime
22+
template:
23+
metadata:
24+
labels:
25+
app: chime
26+
spec:
27+
containers:
28+
- image: docker.pkg.github.com/codeforphilly/chime/penn-chime:0.4.1
29+
name: chime
30+
ports:
31+
- containerPort: 8000
32+
name: http
33+
protocol: TCP
34+
imagePullSecrets:
35+
- name: regcred
36+
---
37+
38+
apiVersion: v1
39+
kind: Service
40+
metadata:
41+
name: chime
42+
namespace: chime
43+
labels:
44+
app: chime
45+
spec:
46+
selector:
47+
app: chime
48+
ports:
49+
- name: http
50+
port: 80
51+
protocol: TCP
52+
targetPort: 8000
53+
54+
---
55+
56+
apiVersion: extensions/v1beta1
57+
kind: Ingress
58+
metadata:
59+
name: chime
60+
namespace: chime
61+
labels:
62+
app: chime
63+
annotations:
64+
kubernetes.io/ingress.class: nginx
65+
certmanager.k8s.io/cluster-issuer: letsencrypt-prod
66+
nginx.ingress.kubernetes.io/proxy-body-size: "0"
67+
spec:
68+
tls:
69+
- hosts:
70+
- penn-chime.bus.phl.io
71+
- penn-chime-alt.bus.phl.io
72+
secretName: tls-secret
73+
rules:
74+
- host: penn-chime.bus.phl.io
75+
http:
76+
paths:
77+
- path: /
78+
backend:
79+
serviceName: chime
80+
servicePort: 80
81+
- host: penn-chime-alt.bus.phl.io
82+
http:
83+
paths:
84+
- path: /
85+
backend:
86+
serviceName: chime
87+
servicePort: 80
88+
89+
---
90+
91+
apiVersion: extensions/v1beta1
92+
kind: Ingress
93+
metadata:
94+
name: chime-static
95+
namespace: chime
96+
labels:
97+
app: chime
98+
annotations:
99+
nginx.ingress.kubernetes.io/proxy-buffering: "on" # Important!
100+
nginx.ingress.kubernetes.io/configuration-snippet: |
101+
proxy_cache static-cache;
102+
proxy_cache_valid 404 1m;
103+
proxy_cache_valid 200 10m;
104+
proxy_cache_use_stale error timeout updating http_404 http_500 http_502 http_503 http_504;
105+
proxy_cache_bypass $http_x_purge;
106+
proxy_cache_key $proxy_upstream_name$request_uri;
107+
proxy_cache_lock on;
108+
proxy_cache_use_stale updating;
109+
add_header X-Cache-Status $upstream_cache_status;
110+
spec:
111+
rules:
112+
- host: penn-chime.bus.phl.io
113+
http:
114+
paths:
115+
- path: /static/
116+
backend:
117+
serviceName: chime
118+
servicePort: 80
119+
- host: penn-chime-alt.bus.phl.io
120+
http:
121+
paths:
122+
- path: /static/
123+
backend:
124+
serviceName: chime
125+
servicePort: 80

0 commit comments

Comments
 (0)