-
Notifications
You must be signed in to change notification settings - Fork 0
/
deploy.yaml
89 lines (86 loc) · 2.1 KB
/
deploy.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
---
apiVersion: serving.knative.dev/v1
kind: Service
metadata:
name: danmu-portal
namespace: default
spec:
template:
metadata:
annotations:
autoscaling.knative.dev/maxScale: "1"
autoscaling.knative.dev/minScale: "1"
spec:
containerConcurrency: 0
serviceAccountName: danmu-install-sa
containers:
- image: registry.cn-hangzhou.aliyuncs.com/knative-sample/danmu-danmu:danmu-lite_b1759f04-20210518200430
name: user-container
env:
- name: URL
value: "http://danmu-message.default.1a5de7167f408bf3.app.alicontainer.com"
ports:
- containerPort: 8080
name: http1
---
apiVersion: serving.knative.dev/v1
kind: Service
metadata:
name: danmu-message
namespace: default
spec:
template:
metadata:
annotations:
autoscaling.knative.dev/maxScale: "10"
autoscaling.knative.dev/minScale: "1"
spec:
containerConcurrency: 2
containers:
- args:
- /manager
- --url=http://danmu-portal.default.1a5de7167f408bf3.app.alicontainer.com/api/send
env:
- name: POD_NAME
valueFrom:
fieldRef:
fieldPath: metadata.name
image: registry.cn-hangzhou.aliyuncs.com/knative-sample/danmu-manager:danmu_48680a04-20210319171906
name: user-container
ports:
- containerPort: 8000
name: http1
---
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRole
metadata:
name: danmu-install
labels:
app: danmu
rules:
- apiGroups: [""]
resources: ["configmaps"]
verbs: ["get", "list"]
---
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
name: danmu-install-role-binding
labels:
app: danmu
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: danmu-install
subjects:
- kind: ServiceAccount
name: danmu-install-sa
namespace: default
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: danmu-install-sa
namespace: default
labels:
app: danmu