forked from rmey/openresty-cos
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdeploy2kube.template
53 lines (53 loc) · 1.05 KB
/
deploy2kube.template
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
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: openresty-cos
spec:
replicas: 1
template:
metadata:
labels:
app: openresty-cos
tier: web
spec:
containers:
- name: openresty-cos
image: @REGISTRY@/openresty-cos
imagePullPolicy: Always
resources:
requests:
cpu: 100m
memory: 100Mi
env:
- name: S3_ACCESS_KEY
value: @S3_ACCESS_KEY@
- name: S3_SECRET_KEY
value: @S3_SECRET_KEY@
- name: S3_BUCKET
value: @S3_BUCKET@
- name: COS_ENDPOINT
value: @COS_ENDPOINT@
- name: COS_URI
value: @COS_URI@
- name: NGINX_LOCATION
value: @NGINX_LOCATION@
---
---
# Service to expose frontend
apiVersion: v1
kind: Service
metadata:
name: openresty-cos
labels:
app: openresty-cos
tier: web
spec:
type: NodePort
ports:
- port: 8080 # Internal Port
nodePort: 31200
selector:
app: openresty-cos
tier: web
---