-
Notifications
You must be signed in to change notification settings - Fork 0
/
serverless.component.yml
234 lines (233 loc) · 6.11 KB
/
serverless.component.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
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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
name: framework
version: 0.1.9
author: Serverless Plus
org: Serverless Plus
description: Deploy a serverless web framework application on Tencent SCF and API Gateway.
keywords: tencent, serverless, framework, web
repo: https://github.com/serverless-plus/tencent-framework
readme: https://github.com/serverless-plus/tencent-framework/tree/master/README.md
license: MIT
main: ./src
webDeployable: true
actions:
deploy:
definition: Deploy web framework application
inputs:
framework:
type: string
required: true
allow:
- express
- koa
- egg
- next
- nuxt
- nest
- laravel
- thinkphp
- flask
- django
src:
type: src
required: true
description: The folder containing the source code of your framework application.
entryFile:
type: string
faas:
type: object
keys:
name:
type: string
description: The name of faas
regex: '^[A-Za-z][\w-_]{0,58}[A-Za-z0-9]$'
region:
type: string
default: ap-guangzhou
description: Region for faas
allow:
- ap-guangzhou
- ap-shanghai
- ap-hongkong
- ap-beijing
- ap-chengdu
- ap-tokyo
- ap-mumbai
- ap-singapore
- na-siliconvalley
- na-toronto
runtime:
type: string
description: faas runtime
default: Nodejs10.15
allow:
- Python2.7
- Python3.6
- Nodejs6.10
- Nodejs8.9
- Nodejs10.15
- Nodejs12.16
- Php5
- Php7
- Go1
- Java8
- CustomRuntime
layers:
type: array
items:
- type: object
keys:
name:
type: string
required: true
version:
type: number
required: true
handler:
type: string
default: 'index.main_handler'
description: The handler of faas
tags:
type: array
description: faas tags
items:
- type: object
keys:
key:
type: string
value:
type: string
environments:
type: array
description: faas environments
items:
- type: object
keys:
key:
type: string
value:
type: string
vpc:
type: object
keys:
vpcId:
type: string
subnetId:
type: string
memorySize:
type: number
description: SCF memory size
default: 128 # The default value
min: 64 # Minimum number allowed
max: 3072 # Maximum number allowed
allow: # The values that are allowed for this
- 64
- 128
- 256
- 384
- 512
- 640
- 768
- 896
- 1024
- 1152
- 1280
- 1408
- 1536
- 1664
- 1792
- 1920
- 2048
- 2176
- 2304
- 2432
- 2560
- 2688
- 2816
- 2944
- 3072
apigw:
type: object
keys:
id:
type: string
regex: '^service-(\w){8,}$'
name:
type: string
description: Name of API Gateway
default: serverless
regex: '^[a-zA-Z][a-zA-Z0-9(_)]{0,48}[a-zA-Z0-9]?$'
static:
type: object
keys:
cos:
type: object
keys:
bucket:
type: string
description: The name of cos
regex: '^[a-z][a-z0-9-]{0,48}[a-z0-9]$'
acl:
type: object
sources:
type: array
items:
- type: object
keys:
src:
type: string
required: true
targetDir:
type: string
required: true
cdn:
type: object
keys:
area:
type: string
allow:
- mainland
- overseas
- global
domain:
type: string
required: true
autoRefresh:
type: boolean
refreshType:
type: string
allow:
- delete
- flush
forceRedirect:
type: object
keys:
switch:
type: string
allow:
- on
- off
redirectType:
type: string
allow:
- http
- https
redirectStatusCode:
type: number
allow:
- 301
- 302
https:
type: object
keys:
http2:
type: string
allow:
- on
- off
certId:
type: string
required: true
remove:
definition: Remove web framework application
metrics:
definition: Get metrics of web framework application