@serverless-devs/s 2.0.95-beta.4 → 2.0.97-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/clean/index.js +1 -1
- package/lib/cli/index.js +1 -1
- package/lib/component/index.js +1 -1
- package/lib/config/add/index.js +1 -1
- package/lib/config/delete/index.js +1 -1
- package/lib/config/get/index.js +1 -1
- package/lib/config/index.js +1 -1
- package/lib/index.js +9 -9
- package/lib/init/index.js +1 -1
- package/lib/set/analysis/index.js +1 -1
- package/lib/set/index.js +1 -1
- package/lib/set/locale/index.js +1 -1
- package/lib/set/registry/index.js +1 -1
- package/lib/set/workspace/index.js +1 -1
- package/lib/update-notifier/index.js +1 -1
- package/package.json +1 -1
- package/readme.md +8 -3
- package/CODE_OF_CONDUCT.md +0 -5
- package/CONTRIBUTING.md +0 -189
- package/CONTRIBUTORS.md +0 -148
- package/docs/readme.md +0 -94
- package/docs/zh/awesome.md +0 -296
- package/docs/zh/cicd.md +0 -200
- package/docs/zh/cli_design.md +0 -100
- package/docs/zh/command/clean.md +0 -63
- package/docs/zh/command/cli.md +0 -92
- package/docs/zh/command/component.md +0 -76
- package/docs/zh/command/config.md +0 -278
- package/docs/zh/command/custom.md +0 -73
- package/docs/zh/command/init.md +0 -148
- package/docs/zh/command/readme.md +0 -76
- package/docs/zh/command/set.md +0 -195
- package/docs/zh/default_provider_config/alibabacloud.md +0 -82
- package/docs/zh/default_provider_config/aws.md +0 -12
- package/docs/zh/default_provider_config/azure.md +0 -9
- package/docs/zh/default_provider_config/baiducloud.md +0 -8
- package/docs/zh/default_provider_config/gcp.md +0 -21
- package/docs/zh/default_provider_config/huaweicloud.md +0 -52
- package/docs/zh/default_provider_config/readme.md +0 -9
- package/docs/zh/default_provider_config/tencentcloud.md +0 -41
- package/docs/zh/install.md +0 -52
- package/docs/zh/package_dev.md +0 -142
- package/docs/zh/quick_start.md +0 -297
- package/docs/zh/readme.md +0 -90
- package/docs/zh/tool.md +0 -80
- package/docs/zh/yaml.md +0 -203
- package/docs/zh/yaml_and_cli.md +0 -67
- package/jest.setup.ts +0 -37
- package/spec/readme.md +0 -59
- package/spec/zh/0.0.1/readme.md +0 -47
- package/spec/zh/0.0.1/serverless_package_model/1.purpose_and_goals.md +0 -3
- package/spec/zh/0.0.1/serverless_package_model/2.overview_and_terminology.md +0 -14
- package/spec/zh/0.0.1/serverless_package_model/3.package_model.md +0 -434
- package/spec/zh/0.0.1/serverless_package_model/4.application_scopes.md +0 -3
- package/spec/zh/0.0.1/serverless_package_model/5.design_principles.md +0 -3
- package/spec/zh/0.0.1/serverless_package_model/readme.md +0 -12
- package/spec/zh/0.0.1/serverless_registry_model/1.purpose_and_goals.md +0 -18
- package/spec/zh/0.0.1/serverless_registry_model/2.overview_and_terminology.md +0 -18
- package/spec/zh/0.0.1/serverless_registry_model/3.registry_model.md +0 -61
- package/spec/zh/0.0.1/serverless_registry_model/4.application_scopes.md +0 -6
- package/spec/zh/0.0.1/serverless_registry_model/5.design_principles.md +0 -3
- package/spec/zh/0.0.1/serverless_registry_model/readme.md +0 -12
- package/spec/zh/0.0.1/serverless_user_model/1.purpose_and_goals.md +0 -3
- package/spec/zh/0.0.1/serverless_user_model/2.overview_and_terminology.md +0 -16
- package/spec/zh/0.0.1/serverless_user_model/3.user_model.md +0 -218
- package/spec/zh/0.0.1/serverless_user_model/4.application_scopes.md +0 -4
- package/spec/zh/0.0.1/serverless_user_model/5.design_principles.md +0 -3
- package/spec/zh/0.0.1/serverless_user_model/readme.md +0 -12
- package/test/ci.sh +0 -33
- package/test/cli/cli-manager.test.ts +0 -64
- package/test/config/get.test.ts +0 -12
- package/test/helloworld.test.ts +0 -7
- package/test/start-fc-http-nodejs12/code/index.js +0 -47
- package/test/start-fc-http-nodejs12/s.yaml +0 -38
- package/test/utils/index.test.ts +0 -8
- package/test/utils/storage.test.ts +0 -19
- package/tsconfig.json +0 -37
package/docs/zh/awesome.md
DELETED
|
@@ -1,296 +0,0 @@
|
|
|
1
|
-
# Package Awesome
|
|
2
|
-
|
|
3
|
-
- [应用集合](#应用集合)
|
|
4
|
-
- [组件集合](#组件集合)
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
# 应用集合
|
|
8
|
-
|
|
9
|
-
## Web Framework应用案例
|
|
10
|
-
|
|
11
|
-
<table>
|
|
12
|
-
<tr>
|
|
13
|
-
<th>No.</th>
|
|
14
|
-
<th>:fire:Nodejs</th>
|
|
15
|
-
<th>Python</th>
|
|
16
|
-
<th>PHP</th>
|
|
17
|
-
<th>Go</th>
|
|
18
|
-
<th>Java</th>
|
|
19
|
-
<th>Others</th>
|
|
20
|
-
</tr>
|
|
21
|
-
<tr>
|
|
22
|
-
<td align="center">1</td>
|
|
23
|
-
<td align="center">:fire:<a href="https://github.com/devsapp/start-express">Express</a></td>
|
|
24
|
-
<td align="center">:fire::fire:<a href="https://github.com/devsapp/start-flask">Flask</a></td>
|
|
25
|
-
<td align="center"><a href="https://github.com/devsapp/start-thinkphp">Think PHP</a></td>
|
|
26
|
-
<td align="center">BeeGo</td>
|
|
27
|
-
<td align="center">Tomcat/Jetty</td>
|
|
28
|
-
<td align="center">Gatsby</td>
|
|
29
|
-
</tr>
|
|
30
|
-
<tr>
|
|
31
|
-
<td align="center">2</td>
|
|
32
|
-
<td align="center"><a href="https://github.com/devsapp/start-egg">Egg</a></td>
|
|
33
|
-
<td align="center"><a href="https://github.com/devsapp/start-tornado">Tornado</a></td>
|
|
34
|
-
<td align="center"><a href="https://github.com/devsapp/start-laravel">laravel</a></td>
|
|
35
|
-
<td align="center">Gin</td>
|
|
36
|
-
<td align="center"><a href="https://github.com/devsapp/start-springboot">Spring Boot</a></td><td>Hugo</td>
|
|
37
|
-
</tr>
|
|
38
|
-
<tr>
|
|
39
|
-
<td align="center">3</td>
|
|
40
|
-
<td align="center"><a href="https://github.com/devsapp/start-next">Nextjs</a></td>
|
|
41
|
-
<td align="center"><a href="https://github.com/devsapp/start-bottle">Bottle</a></td>
|
|
42
|
-
<td align="center"><a href="https://github.com/devsapp/start-discuz">Discuz</a></td><td></td><td align="center">Quarkus</td>
|
|
43
|
-
<td align="center"></td>
|
|
44
|
-
</tr>
|
|
45
|
-
<tr>
|
|
46
|
-
<td align="center">4</td>
|
|
47
|
-
<td align="center"><a href="https://github.com/devsapp/start-nuxt">Nuxtjs(Container)</a><br><a href="https://github.com/devsapp/custom-nuxt">Nuxtjs(Custom)</a></td>
|
|
48
|
-
<td align="center"><a href="https://github.com/devsapp/start-webpy">Web.py</a></td>
|
|
49
|
-
<td align="center"> :fire::fire::fire: <a href="https://github.com/devsapp/start-wordpress" >WordPress</a></td><td></td><td></td>
|
|
50
|
-
<td align="center"></td>
|
|
51
|
-
</tr>
|
|
52
|
-
<tr>
|
|
53
|
-
<td align="center">5</td>
|
|
54
|
-
<td align="center"> :fire::fire::fire: <a href="https://github.com/devsapp/start-hexo" >Hexo</a></td>
|
|
55
|
-
<td align="center"><a href="https://github.com/devsapp/start-django" >Django</a></td>
|
|
56
|
-
<td align="center"> :fire::fire::fire: <a href="https://github.com/devsapp/start-zblog" >Zblog</a></td><td></td><td></td>
|
|
57
|
-
<td align="center"></td>
|
|
58
|
-
</tr>
|
|
59
|
-
<tr>
|
|
60
|
-
<td align="center">6</td>
|
|
61
|
-
<td align="center"><a href="https://github.com/devsapp/start-koa">Koa(Container)</a><br><a href="https://github.com/devsapp/nodejs-koa">Koa(Node.js Runtime)</a></td>
|
|
62
|
-
<td align="center">FastAPI</td>
|
|
63
|
-
<td align="center"><a href="https://github.com/devsapp/start-ecshop" >Ecshop</a></td><td></td><td></td><td></td>
|
|
64
|
-
</tr>
|
|
65
|
-
<tr>
|
|
66
|
-
<td align="center">7</td>
|
|
67
|
-
<td align="center"><a href="https://github.com/devsapp/start-hapi" >Hapi</a></td>
|
|
68
|
-
<td align="center">Web2py</td>
|
|
69
|
-
<td align="center"><a href="https://github.com/devsapp/start-metinfo" >Metinfo</a></td>
|
|
70
|
-
<td></td><td></td><td></td>
|
|
71
|
-
</tr>
|
|
72
|
-
<tr>
|
|
73
|
-
<td align="center">8</td>
|
|
74
|
-
<td align="center"><a href="https://github.com/devsapp/start-expresscart">Expresscart</a></td>
|
|
75
|
-
<td align="center"><a href="https://github.com/devsapp/start-pyramid" >Pyramid</a></td>
|
|
76
|
-
<td align="center"><a href="https://github.com/devsapp/start-whatsns" >Whatsns</a></td><td></td><td></td><td></td>
|
|
77
|
-
</tr>
|
|
78
|
-
<tr>
|
|
79
|
-
<td align="center">9</td>
|
|
80
|
-
<td align="center"></td>
|
|
81
|
-
<td align="center"></td>
|
|
82
|
-
<td align="center"><a href="https://github.com/devsapp/start-typecho" >Typecho</a></td><td></td><td></td><td></td>
|
|
83
|
-
</tr>
|
|
84
|
-
</table>
|
|
85
|
-
|
|
86
|
-
## 静态网站应用案例
|
|
87
|
-
|
|
88
|
-
静态网站案例:https://github.com/devsapp/website-example
|
|
89
|
-
- 普通静态资源应用: `s init devsapp/website-example:website-base`
|
|
90
|
-
- react应用 `s init devsapp/website-example:website-react`
|
|
91
|
-
- vue应用 `s init devsapp/website-example:website-vue`
|
|
92
|
-
- hexo应用 `s init devsapp/website-example:website-hexo`
|
|
93
|
-
- docusaurus应用 `s init devsapp/website-example:website-docusaurus`
|
|
94
|
-
- vuepress应用 `s init devsapp/website-example:website-vuepress`
|
|
95
|
-
|
|
96
|
-
## 开源框架应用案例
|
|
97
|
-
- Midway FaaS:https://github.com/devsapp/midway-hook-example
|
|
98
|
-
- react模板: `s init devsapp/midway-hook-example:midway-hook-react`
|
|
99
|
-
- vue模板 `s init devsapp/midway-hook-example:midway-hook-vue`
|
|
100
|
-
- Malagu:https://github.com/devsapp/start-s-malagu
|
|
101
|
-
|
|
102
|
-
## 场景合集
|
|
103
|
-
|
|
104
|
-
### Blog集合
|
|
105
|
-
- Zblog: https://github.com/devsapp/start-zblog `s init devsapp/start-zblog`
|
|
106
|
-
- Wordpress: https://github.com/devsapp/start-wordpress `s init devsapp/start-wordpress`
|
|
107
|
-
- Hexo: https://github.com/devsapp/start-hexo `s init devsapp/start-hexo`
|
|
108
|
-
- Vuepress: https://github.com/devsapp/website-example `s init devsapp/website-example:website-vuepress`
|
|
109
|
-
- Django Blog: https://github.com/devsapp/django-blog `s init devsapp/django-zblog`
|
|
110
|
-
- Typecho: https://github.com/devsapp/start-typecho `s init devsapp/start-typecho`
|
|
111
|
-
|
|
112
|
-
### 企业官网
|
|
113
|
-
- Metinfo: https://github.com/devsapp/start-metinfo `s init devsapp/start-metinfo`
|
|
114
|
-
|
|
115
|
-
### 社区问答
|
|
116
|
-
- Whatsns: https://github.com/devsapp/start-whatsns `s init devsapp/start-whatsns`
|
|
117
|
-
- Discuz: https://github.com/devsapp/start-discuz `s init devsapp/start-discuz`
|
|
118
|
-
|
|
119
|
-
### 电子商务
|
|
120
|
-
- Echsop: https://github.com/devsapp/start-ecshop `s init devsapp/start-ecshop`
|
|
121
|
-
- Expresscart: https://github.com/devsapp/start-expresscart `s init devsapp/start-expresscart`
|
|
122
|
-
|
|
123
|
-
### 其他
|
|
124
|
-
- 该项目模板是一个基于 puppeteer 的截图 Web 应用:
|
|
125
|
-
- https://github.com/devsapp/puppeteer-app `s init devsapp/puppeteer-app`
|
|
126
|
-
- https://github.com/devsapp/start-puppeteer `s init devsapp/start-puppeteer`
|
|
127
|
-
- 一款基于人工智能的目标检测应用: https://github.com/devsapp/image-prediction-app `s init devsapp/image-prediction-app`
|
|
128
|
-
- 一款基于Node.JS的网页TodoList应用: https://github.com/devsapp/todolist-app `s init devsapp/todolist-app`
|
|
129
|
-
- 基于函数计算 FC + FFmpeg 实现 Serverless 架构的弹性高可用的高度自定义音视频处理主题: https://github.com/devsapp/ffmpeg-app `s init devsapp/ffmpeg-app`
|
|
130
|
-
- 对直播视频流截图的应用: https://github.com/devsapp/start-rtmp-snapshot `s init start-rtmp-snapshot`
|
|
131
|
-
- 一个对浏览器全景录制: https://github.com/devsapp/start-headless-ffmpeg `s init start-headless-ffmpeg`
|
|
132
|
-
- 一个word转pdf的应用: https://github.com/devsapp/start-word2pdf `s init start-word2pdf`
|
|
133
|
-
- 一个pdf转图片的应用: https://github.com/devsapp/start-pdf2img `s init start-pdf2img`
|
|
134
|
-
- 在Serverless架构玩转pyTorch: https://github.com/devsapp/start-pytorch `s init start-pytorch`
|
|
135
|
-
- 在Serverless架构玩转Tensorflow: https://github.com/devsapp/start-tensorflow `s init start-tensorflow`
|
|
136
|
-
- Serverless架构的OCR工具: https://github.com/devsapp/start-ocr `s init start-ocr`
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
## 静态网站应用案例
|
|
140
|
-
|
|
141
|
-
静态网站案例:https://github.com/devsapp/website-example
|
|
142
|
-
- 普通静态资源应用: `s init devsapp/website-example:website-base`
|
|
143
|
-
- react应用 `s init devsapp/website-example:website-react`
|
|
144
|
-
- vue应用 `s init devsapp/website-example:website-vue`
|
|
145
|
-
- hexo应用 `s init devsapp/website-example:website-hexo`
|
|
146
|
-
- docusaurus应用 `s init devsapp/website-example:website-docusaurus`
|
|
147
|
-
- vuepress应用 `s init devsapp/website-example:website-vuepress`
|
|
148
|
-
|
|
149
|
-
## Alinode
|
|
150
|
-
可观测性:
|
|
151
|
-
- Insight: https://github.com/devsapp/alinode-faas-insight
|
|
152
|
-
- Runtime Http: https://github.com/devsapp/alinode-runtime-http
|
|
153
|
-
- FaaS Logs: https://github.com/devsapp/alinode-faas-sls-log
|
|
154
|
-
- Runtime Deploy: https://github.com/devsapp/alinode-runtime-deploy
|
|
155
|
-
|
|
156
|
-
## 开源框架应用案例
|
|
157
|
-
- Midway FaaS:https://github.com/devsapp/midway-hook-example
|
|
158
|
-
- react模板: `s init devsapp/midway-hook-example:midway-hook-react`
|
|
159
|
-
- vue模板 `s init devsapp/midway-hook-example:midway-hook-vue`
|
|
160
|
-
- Malagu:https://github.com/devsapp/start-s-malagu
|
|
161
|
-
|
|
162
|
-
## 场景合集
|
|
163
|
-
|
|
164
|
-
### Blog集合
|
|
165
|
-
- Zblog: https://github.com/devsapp/start-zblog `s init devsapp/start-zblog`
|
|
166
|
-
- Wordpress: https://github.com/devsapp/start-wordpress `s init devsapp/start-wordpress`
|
|
167
|
-
- Hexo: https://github.com/devsapp/start-hexo `s init devsapp/start-hexo`
|
|
168
|
-
- Vuepress: https://github.com/devsapp/website-example `s init devsapp/website-example:website-vuepress`
|
|
169
|
-
- Django Blog: https://github.com/devsapp/django-blog `s init devsapp/django-zblog`
|
|
170
|
-
- Typecho: https://github.com/devsapp/start-typecho `s init devsapp/start-typecho`
|
|
171
|
-
|
|
172
|
-
### 企业官网
|
|
173
|
-
- Metinfo: https://github.com/devsapp/start-metinfo `s init devsapp/start-metinfo`
|
|
174
|
-
|
|
175
|
-
### 社区问答
|
|
176
|
-
- Whatsns: https://github.com/devsapp/start-whatsns `s init devsapp/start-whatsns`
|
|
177
|
-
- Discuz: https://github.com/devsapp/start-discuz `s init devsapp/start-discuz`
|
|
178
|
-
|
|
179
|
-
### 电子商务
|
|
180
|
-
- Echsop: https://github.com/devsapp/start-ecshop `s init devsapp/start-ecshop`
|
|
181
|
-
- Expresscart: https://github.com/devsapp/start-expresscart `s init devsapp/start-expresscart`
|
|
182
|
-
|
|
183
|
-
### 其他
|
|
184
|
-
- 该项目模板是一个基于 puppeteer 的截图 Web 应用:
|
|
185
|
-
- https://github.com/devsapp/puppeteer-app `s init devsapp/puppeteer-app`
|
|
186
|
-
- https://github.com/devsapp/start-puppeteer `s init devsapp/start-puppeteer`
|
|
187
|
-
- 一款基于人工智能的目标检测应用: https://github.com/devsapp/image-prediction-app `s init devsapp/image-prediction-app`
|
|
188
|
-
- 一款基于Node.JS的网页TodoList应用: https://github.com/devsapp/todolist-app `s init devsapp/todolist-app`
|
|
189
|
-
- 基于函数计算 FC + FFmpeg 实现 Serverless 架构的弹性高可用的高度自定义音视频处理主题: https://github.com/devsapp/ffmpeg-app `s init devsapp/ffmpeg-app`
|
|
190
|
-
- 对直播视频流截图的应用: https://github.com/devsapp/start-rtmp-snapshot `s init start-rtmp-snapshot`
|
|
191
|
-
- 一个对浏览器全景录制: https://github.com/devsapp/start-headless-ffmpeg `s init start-headless-ffmpeg`
|
|
192
|
-
- 一个word转pdf的应用: https://github.com/devsapp/start-word2pdf `s init start-word2pdf`
|
|
193
|
-
- 一个pdf转图片的应用: https://github.com/devsapp/start-pdf2img `s init start-pdf2img`
|
|
194
|
-
- 在Serverless架构玩转pyTorch: https://github.com/devsapp/start-pytorch `s init start-pytorch`
|
|
195
|
-
- 在Serverless架构玩转Tensorflow: https://github.com/devsapp/start-tensorflow `s init start-tensorflow`
|
|
196
|
-
- Serverless架构的OCR工具: https://github.com/devsapp/start-ocr `s init start-ocr`
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
# 组件集合
|
|
200
|
-
|
|
201
|
-
## 基础组件
|
|
202
|
-
|
|
203
|
-
- 阿里云
|
|
204
|
-
- 函数计算(FC):
|
|
205
|
-
- Yaml描述:https://github.com/devsapp/fc
|
|
206
|
-
- 命令行交互:https://github.com/devsapp/fc-api (可以在无Yaml模式下直接进行使用)
|
|
207
|
-
- Serverless工作流(FNF):https://github.com/devsapp/fnf
|
|
208
|
-
- 腾讯云
|
|
209
|
-
- 云函数(SCF):https://github.com/devscomp/scf
|
|
210
|
-
- AWS
|
|
211
|
-
- Lambda:https://github.com/devscomp/lambda
|
|
212
|
-
- 百度云
|
|
213
|
-
- 函数计算(CFC):https://github.com/xinwuyun/cfc
|
|
214
|
-
- 华为云
|
|
215
|
-
- 函数工作流(FG):https://github.com/xinwuyun/fg
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
## 上层组件
|
|
221
|
-
|
|
222
|
-
<table>
|
|
223
|
-
<tr>
|
|
224
|
-
<th>No.</th>
|
|
225
|
-
<th>:fire:Nodejs</th>
|
|
226
|
-
<th>Python</th>
|
|
227
|
-
<th>PHP</th>
|
|
228
|
-
<th>Go</th>
|
|
229
|
-
<th>Java</th>
|
|
230
|
-
<th>Others</th>
|
|
231
|
-
</tr>
|
|
232
|
-
<tr>
|
|
233
|
-
<td align="center">1</td>
|
|
234
|
-
<td align="center">:fire:<a href="https://github.com/devsapp/express">Express</a></td>
|
|
235
|
-
<td align="center">:fire::fire:<a href="https://github.com/devsapp/flask">Flask</a></td>
|
|
236
|
-
<td align="center"><a href="https://github.com/devsapp/thinkphp">Think PHP</a></td>
|
|
237
|
-
<td align="center">BeeGo</td>
|
|
238
|
-
<td align="center">Tomcat/Jetty</td>
|
|
239
|
-
<td align="center">Gatsby</td>
|
|
240
|
-
</tr>
|
|
241
|
-
<tr>
|
|
242
|
-
<td align="center">2</td>
|
|
243
|
-
<td align="center"><a href="https://github.com/devsapp/egg">Egg</a></td>
|
|
244
|
-
<td align="center"><a href="https://github.com/devsapp/tornado">Tornado</a></td>
|
|
245
|
-
<td align="center"><a href="https://github.com/devsapp/laravel">laravel</a></td>
|
|
246
|
-
<td align="center">Gin</td>
|
|
247
|
-
<td align="center">Spring Boot</td>
|
|
248
|
-
<td align="center">Hugo</td>
|
|
249
|
-
</tr>
|
|
250
|
-
<tr>
|
|
251
|
-
<td align="center">3</td>
|
|
252
|
-
<td align="center"><a href="https://github.com/devsapp/next">Nextjs</a></td>
|
|
253
|
-
<td align="center"><a href="https://github.com/devsapp/bottle">Bottle</a></td>
|
|
254
|
-
<td align="center"><a href="https://github.com/devsapp/discuz">Discuz</a></td><td></td><td align="center">Quarkus</td>
|
|
255
|
-
<td align="center">:fire::fire:<a href="https://github.com/devsapp/midway-hook">Midway FaaS</a></td>
|
|
256
|
-
</tr>
|
|
257
|
-
<tr>
|
|
258
|
-
<td align="center">4</td>
|
|
259
|
-
<td align="center"><a href="https://github.com/devsapp/nuxt">Nuxtjs</a></td>
|
|
260
|
-
<td align="center"><a href="https://github.com/devsapp/webpy">Web.py</a></td>
|
|
261
|
-
<td align="center"> :fire::fire::fire: <a href="https://github.com/devsapp/wordpress" >WordPress</a></td><td></td><td></td>
|
|
262
|
-
<td align="center">:fire:<a href="https://github.com/devsapp/s-malagu">Malagu</a></td>
|
|
263
|
-
</tr>
|
|
264
|
-
<tr>
|
|
265
|
-
<td align="center">5</td>
|
|
266
|
-
<td align="center"> :fire::fire::fire: <a href="https://github.com/devsapp/hexo" >Hexo</a></td>
|
|
267
|
-
<td align="center"><a href="https://github.com/devsapp/django" >Django</a></td>
|
|
268
|
-
<td align="center"> :fire::fire::fire: <a href="https://github.com/devsapp/zblog" >Zblog</a></td><td></td><td></td>
|
|
269
|
-
<td align="center">:fire::fire::fire:<a href="https://github.com/devsapp/website">Website</a></td>
|
|
270
|
-
</tr>
|
|
271
|
-
<tr>
|
|
272
|
-
<td align="center">6</td>
|
|
273
|
-
<td align="center"><a href="https://github.com/devsapp/koa" >Koa</a></td>
|
|
274
|
-
<td align="center">FastAPI</td>
|
|
275
|
-
<td align="center"><a href="https://github.com/devsapp/ecshop" >Ecshop</a></td><td></td><td></td><td></td>
|
|
276
|
-
</tr>
|
|
277
|
-
<tr>
|
|
278
|
-
<td align="center">7</td>
|
|
279
|
-
<td align="center"><a href="https://github.com/devsapp/hapi" >Hapi</a></td>
|
|
280
|
-
<td align="center">Web2py</td>
|
|
281
|
-
<td align="center"><a href="https://github.com/devsapp/metinfo" >Metinfo</a></td>
|
|
282
|
-
<td></td><td></td><td></td>
|
|
283
|
-
</tr>
|
|
284
|
-
<tr>
|
|
285
|
-
<td align="center">8</td>
|
|
286
|
-
<td align="center"></td>
|
|
287
|
-
<td align="center"><a href="https://github.com/devsapp/pyramid" >Pyramid</a></td>
|
|
288
|
-
<td align="center"><a href="https://github.com/devsapp/whatsns" >Whatsns</a></td><td></td><td></td><td></td>
|
|
289
|
-
</tr>
|
|
290
|
-
<tr>
|
|
291
|
-
<td align="center">9</td>
|
|
292
|
-
<td align="center"></td>
|
|
293
|
-
<td align="center"></td>
|
|
294
|
-
<td align="center"><a href="https://github.com/devsapp/typecho" >Typecho</a></td><td></td><td></td><td></td>
|
|
295
|
-
</tr>
|
|
296
|
-
</table>
|
package/docs/zh/cicd.md
DELETED
|
@@ -1,200 +0,0 @@
|
|
|
1
|
-
# 与 CI/CD 平台/工具集成
|
|
2
|
-
|
|
3
|
-
- [与 Github Action 的集成](#与-github-action-的集成)
|
|
4
|
-
- [与 Gitee Go 的集成](#与-gitee-go-的集成)
|
|
5
|
-
- [与 Jenkins 的集成](#与-jenkins-的集成)
|
|
6
|
-
- [注意事项](#注意事项)
|
|
7
|
-
|
|
8
|
-
## 与 Github Action 的集成
|
|
9
|
-
|
|
10
|
-
在 Github Action 的 Yaml 文件中,可以增加 Serverless Devs 的相关下载、配置以及命令执行相关能力。
|
|
11
|
-
|
|
12
|
-
例如,在仓库中可以创建该文件`.github/workflows/publish.yml`,文件内容:
|
|
13
|
-
|
|
14
|
-
```yaml
|
|
15
|
-
name: Serverless Devs Project CI/CD
|
|
16
|
-
|
|
17
|
-
on:
|
|
18
|
-
push:
|
|
19
|
-
branches: [ master ]
|
|
20
|
-
|
|
21
|
-
jobs:
|
|
22
|
-
serverless-devs-cd:
|
|
23
|
-
runs-on: ubuntu-latest
|
|
24
|
-
steps:
|
|
25
|
-
- uses: actions/checkout@v2
|
|
26
|
-
- uses: actions/setup-node@v2
|
|
27
|
-
with:
|
|
28
|
-
node-version: 12
|
|
29
|
-
registry-url: https://registry.npmjs.org/
|
|
30
|
-
- run: npm install
|
|
31
|
-
- run: npm install -g @serverless-devs/s
|
|
32
|
-
- run: s config add --AccountID ${{secrets.AccountID}} --AccessKeyID ${{secrets.AccessKeyID}} --AccessKeySecret ${{secrets.AccessKeySecret}} -a default
|
|
33
|
-
- run: s deploy
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
主要包括几个部分的内容:
|
|
37
|
-
- `run: npm install -g @serverless-devs/s`:
|
|
38
|
-
通过NPM安装最新版本的 Serverless Devs 开发者工具;
|
|
39
|
-
- `run: s config add --AccountID ${{secrets.AccountID}} --AccessKeyID ${{secrets.AccessKeyID}} --AccessKeySecret ${{secrets.AccessKeySecret}} -a default`
|
|
40
|
-
通过`config`命令进行密钥等信息的配置;
|
|
41
|
-
- `run: s deploy`
|
|
42
|
-
执行某些命令,例如通过`deploy`进行项目的部署,或者`build`等命令进行构建等;
|
|
43
|
-
|
|
44
|
-
关于密钥的配置:密钥信息的获取是通过`${{secrets.*}}`进行获取的,所以此时,需要将所需要的密钥和对应的`Key`配置到 Github Secrets 中,例如在上面的案例中,需要`AccountID`,`AccessKeyID`,`AccessKeySecret`等三个密钥的 Key ,我们就可以配置相关的内容:
|
|
45
|
-
|
|
46
|
-
1. 将密钥信息配置到Github Secrets中
|
|
47
|
-

|
|
48
|
-
|
|
49
|
-
2. 我们创建多对密钥信息:
|
|
50
|
-

|
|
51
|
-
例如,我此处配置了三对密钥:
|
|
52
|
-

|
|
53
|
-
|
|
54
|
-
> 关于密钥配置的部分注意内容,可以参考文末的[注意事项](#注意事项)
|
|
55
|
-
|
|
56
|
-
## 与 Gitee Go 的集成
|
|
57
|
-
|
|
58
|
-
在开启 Gitee Go 的服务之后,在流水线的 Yaml 文件中,可以增加 Serverless Devs 的相关下载、配置以及命令执行相关能力。
|
|
59
|
-
|
|
60
|
-
例如,在仓库中可以创建该文件`.github/workflows/publish.yml`,文件内容:
|
|
61
|
-
|
|
62
|
-
```yaml
|
|
63
|
-
name: serverless-devs
|
|
64
|
-
displayName: 'Serverless Devs Project CI/CD'
|
|
65
|
-
triggers: # 流水线触发器配置
|
|
66
|
-
push: # 设置 master 分支 在产生代码 push 时精确触发(PRECISE)构建
|
|
67
|
-
- matchType: PRECISE
|
|
68
|
-
branch: master
|
|
69
|
-
commitMessage: '' # 通过匹配当前提交的 CommitMessage 决定是否执行流水线
|
|
70
|
-
stages: # 构建阶段配置
|
|
71
|
-
- stage: # 定义一个 ID 标识为 deploy-stage ,名为「 Deploy Stage 」的阶段
|
|
72
|
-
name: deploy-stage
|
|
73
|
-
displayName: 'Deploy Stage'
|
|
74
|
-
failFast: false # 允许快速失败,即当 Stage 中有任务失败时,直接结束整个 Stage
|
|
75
|
-
|
|
76
|
-
steps: # 构建步骤配置
|
|
77
|
-
- step: npmbuild@1 # 采用 npm 编译环境
|
|
78
|
-
name: deploy-step # 定义一个 ID 标识为 deploy-step ,名为「 Deploy Step 」的阶段
|
|
79
|
-
displayName: 'Deploy Step'
|
|
80
|
-
inputs: # 构建输入参数设定
|
|
81
|
-
nodeVersion: 14.15 # 指定 node 环境版本为 14.15
|
|
82
|
-
goals: | # 安装依赖,配置相关主题、部署参数并发布部署
|
|
83
|
-
node -v
|
|
84
|
-
npm -v
|
|
85
|
-
npm install -g @serverless-devs/s
|
|
86
|
-
s config add --AccountID $ACCOUNTID --AccessKeyID $ACCESSKEYID --AccessKeySecret $ACCESSKEYSECRET -a default
|
|
87
|
-
s deploy
|
|
88
|
-
```
|
|
89
|
-
|
|
90
|
-
主要包括几个部分的内容:
|
|
91
|
-
- `npm install -g @serverless-devs/s`:
|
|
92
|
-
通过NPM安装最新版本的 Serverless Devs 开发者工具;
|
|
93
|
-
- `s config add --AccountID $ACCOUNTID --AccessKeyID $ACCESSKEYID --AccessKeySecret $ACCESSKEYSECRET -a default`
|
|
94
|
-
通过`config`命令进行密钥等信息的配置;
|
|
95
|
-
- `s deploy`
|
|
96
|
-
执行某些命令,例如通过`deploy`进行项目的部署,或者`build`等命令进行构建等;
|
|
97
|
-
|
|
98
|
-
关于密钥的配置:密钥信息的获取是通过`$*`进行获取的,所以此时,需要将所需要的密钥和对应的`Key`配置到 Gitee 的环境变量管理即可,例如在上面的案例中,需要`ACCOUNTID`,`ACCESSKEYID`,`ACCESSKEYSECRET`等三个密钥的 Key ,我们就可以配置相关的内容:
|
|
99
|
-
|
|
100
|
-
1. 找到 Gitee 的环境变量管理
|
|
101
|
-

|
|
102
|
-
|
|
103
|
-
2. 我们创建多对密钥信息:
|
|
104
|
-

|
|
105
|
-
例如,我此处配置了三对密钥:
|
|
106
|
-

|
|
107
|
-
|
|
108
|
-
> 关于密钥配置的部分注意内容,可以参考文末的[注意事项](#注意事项)
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
## 与 Jenkins 的集成
|
|
112
|
-
|
|
113
|
-
在准备将 Serverless Devs 集成到 Jenkins 之前,需要先基于 [Jenkins 官网](https://www.jenkins.io/zh/doc/pipeline/tour/getting-started/) 安装并运行 Jenkins。
|
|
114
|
-
|
|
115
|
-
本地启动 Jenkins 后,通过浏览器进入链接 `http://localhost:8080` 配置完成基础设置后,需要新增 Credentials 设置,如下图所示:
|
|
116
|
-
|
|
117
|
-

|
|
118
|
-
|
|
119
|
-
此时可以根据需要,增加密钥信息,以阿里云为例,新增三个全局凭据:
|
|
120
|
-
|
|
121
|
-
```
|
|
122
|
-
jenkins-alicloud-account-id : 阿里云 accountId
|
|
123
|
-
|
|
124
|
-
jenkins-alicloud-access-key-id : 阿里云 accessKeyId
|
|
125
|
-
|
|
126
|
-
jenkins-alicloud-access-key-secret : 阿里云 accessKeySecret
|
|
127
|
-
```
|
|
128
|
-
|
|
129
|
-
> 新增 Credentials 的教程可以参考[这里](https://www.jenkins.io/zh/doc/book/using/using-credentials/)。
|
|
130
|
-
|
|
131
|
-
此时,可以对自身的 Serverless Devs 项目进行完善:
|
|
132
|
-
|
|
133
|
-
- 创建文件`Jenkinsfile`
|
|
134
|
-
```
|
|
135
|
-
pipeline {
|
|
136
|
-
agent {
|
|
137
|
-
docker {
|
|
138
|
-
image 'maven:3.3-jdk-8'
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
environment {
|
|
143
|
-
ALICLOUD_ACCESS = 'default'
|
|
144
|
-
ALICLOUD_ACCOUNT_ID = credentials('jenkins-alicloud-account-id')
|
|
145
|
-
ALICLOUD_ACCESS_KEY_ID = credentials('jenkins-alicloud-access-key-id')
|
|
146
|
-
ALICLOUD_ACCESS_KEY_SECRET = credentials('jenkins-alicloud-access-key-secret')
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
stages {
|
|
150
|
-
stage('Setup') {
|
|
151
|
-
steps {
|
|
152
|
-
sh 'scripts/setup.sh'
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
```
|
|
158
|
-
主要的内容包括两个部分:
|
|
159
|
-
- environment 部分,主要是根据上面步骤配置的密钥信息,进行密钥的处理;
|
|
160
|
-
- stages 部分,这里面会有一个部分是`sh 'scripts/setup.sh'`,即运行`scripts/setup.sh`文件,进行相关内容的准备和配置;
|
|
161
|
-
- 准备`scripts/setup.sh`文件,只需要在项目下,创建该文件即可:
|
|
162
|
-
```shell script
|
|
163
|
-
#!/usr/bin/env bash
|
|
164
|
-
|
|
165
|
-
echo $(pwd)
|
|
166
|
-
curl -o- -L http://cli.so/install.sh | bash
|
|
167
|
-
|
|
168
|
-
source ~/.bashrc
|
|
169
|
-
|
|
170
|
-
echo $ALICLOUD_ACCOUNT_ID
|
|
171
|
-
s config add --AccountID $ALICLOUD_ACCOUNT_ID --AccessKeyID $ALICLOUD_ACCESS_KEY_ID --AccessKeySecret $ALICLOUD_ACCESS_KEY_SECRET -a $ALICLOUD_ACCESS
|
|
172
|
-
|
|
173
|
-
(cd code && mvn package && echo $(pwd))
|
|
174
|
-
|
|
175
|
-
s deploy -y --use-local --access $ALICLOUD_ACCESS
|
|
176
|
-
```
|
|
177
|
-
在该文件中,主要包括了几个部分:
|
|
178
|
-
- `curl -o- -L http://cli.so/install.sh | bash`
|
|
179
|
-
下载并安装 Serverless Devs 开发者工具
|
|
180
|
-
- `s config add --AccountID $ALICLOUD_ACCOUNT_ID --AccessKeyID $ALICLOUD_ACCESS_KEY_ID --AccessKeySecret $ALICLOUD_ACCESS_KEY_SECRET -a $ALICLOUD_ACCESS`
|
|
181
|
-
配置密钥信息等内容
|
|
182
|
-
- `s deploy -y --use-local --access $ALICLOUD_ACCESS`
|
|
183
|
-
执行某些命令,例如通过`deploy`进行项目的部署,或者`build`等命令进行构建等;
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
完成密钥配置之后,可以创建一个 Jenkins 流水线,该流水线的源是目标 github 地址。接下来,就可以开始运行 Jenkins 流水线,运行结束后,就可以得到相关的内容结果。
|
|
187
|
-
|
|
188
|
-
> 关于密钥配置的部分注意内容,可以参考文末的[注意事项](#注意事项)
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
## 注意事项
|
|
192
|
-
|
|
193
|
-
- 在配置密钥的时候,使用了`s config add`命令,此时在最后有一个参数是`-a default`,代表的是给该密钥一个叫`default`的别名,这个别名要和项目所设定的使用密钥保持一致,例如在`s.yaml`中的`access`字段;
|
|
194
|
-
- 如果在当前应用在,涉及到了配置部署到不同的平台或者账号下,可能会涉及到配置多个密钥信息,此时需要给不同的密钥不同的别名,并且在`s.yaml`中进行使用;
|
|
195
|
-
- 如果想要配置更为灵活的密钥信息,可以考虑通过`-il`和`-kl`参数获取,例如同时配置两对密钥,并且使用自定义 Key :
|
|
196
|
-
```yaml
|
|
197
|
-
s config add -kl tempToken1,tempToken2 -il tempValue1,tempValue2 -a website_access
|
|
198
|
-
s config add -kl tempToken3,tempToken4 -il tempValue3,tempValue4 -a fc_access
|
|
199
|
-
```
|
|
200
|
-
|
package/docs/zh/cli_design.md
DELETED
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
# 命令行设计规范
|
|
2
|
-
|
|
3
|
-
Serverless Devs 作为 Serverless 领域的开发者工具,其输出的标准化和规范化会在一定程度上对用户体验有比较明显的影响。
|
|
4
|
-
|
|
5
|
-
本文档将会通过一些文字和案例,对Serverless Devs的命令行工具输出,进行规范化升级。
|
|
6
|
-
|
|
7
|
-
## 规范详情
|
|
8
|
-
|
|
9
|
-
输出格式的规范目标是:
|
|
10
|
-
|
|
11
|
-
- 更清晰
|
|
12
|
-
- 更简约
|
|
13
|
-
- 不影响功能实用
|
|
14
|
-
|
|
15
|
-
基于以上三个原则,我们可以通过正常输出的形式、异常输出的形式等分别进行举例说明
|
|
16
|
-
|
|
17
|
-
### 基本输出
|
|
18
|
-
|
|
19
|
-
基本输出的形式,整体上包括两个部分:
|
|
20
|
-
|
|
21
|
-
1. 项目执行阶段
|
|
22
|
-
|
|
23
|
-
项目执行阶段主要包括一个基本格式:
|
|
24
|
-
|
|
25
|
-
```
|
|
26
|
-
⌛ Steps for process
|
|
27
|
-
====================
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
采用重写机制,不断的更新输出内容,每个项目执行完成可以输出相对应的结果,示例:
|
|
31
|
-
|
|
32
|
-
```
|
|
33
|
-
⌛ Steps for process
|
|
34
|
-
====================
|
|
35
|
-
✔ Pre-action completed (10s)
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
2. 结果输出阶段
|
|
39
|
-
|
|
40
|
-
项目执行阶段主要包括一个基本格式:
|
|
41
|
-
|
|
42
|
-
```
|
|
43
|
-
🚀 Result for process
|
|
44
|
-
====================
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
具体的项目输出采用`Yaml`的格式进行输出,输出时,项目名称要加下划线,如果没有输出则直接结束项目,示例:
|
|
48
|
-
|
|
49
|
-
```
|
|
50
|
-
🚀 Result for process
|
|
51
|
-
====================
|
|
52
|
-
✔ MyProject deployed (11s)
|
|
53
|
-
fc-deploy-test:
|
|
54
|
-
region: cn-hangzhou
|
|
55
|
-
service:
|
|
56
|
-
name: fc-deploy-service
|
|
57
|
-
memorySize: 128
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
#### 单项目输出示例
|
|
61
|
-
|
|
62
|
-

|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
#### 多项目输出示例
|
|
66
|
-
|
|
67
|
-

|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
### 调试模式
|
|
71
|
-
|
|
72
|
-
当用户使用`--debug`进入到调试模式,则会打印非常详细的信息在控制台,但是这些信息将会以灰色形式打印出来,以保持整体的层次感:
|
|
73
|
-
|
|
74
|
-

|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
### 错误输出
|
|
79
|
-
|
|
80
|
-
当执行出现错误时,Serverless Devs要做到感知并输出相对应的内容:
|
|
81
|
-
|
|
82
|
-
```
|
|
83
|
-
⌛ Steps for process
|
|
84
|
-
====================
|
|
85
|
-
✔ MyProject pre-action completed (10s)
|
|
86
|
-
✖ MyProject failed to deploy:
|
|
87
|
-
|
|
88
|
-
Error Message:
|
|
89
|
-
t[r] is not a function
|
|
90
|
-
|
|
91
|
-
Env: darwin, node v15.14.0
|
|
92
|
-
Docs: https://github.com/serverless-devs/docs
|
|
93
|
-
Bugs: https://github.com/Serverless-Devs/Serverless-Devs/issues
|
|
94
|
-
Logs: ~/demo/demo/demo/s.log
|
|
95
|
-
```
|
|
96
|
-
|
|
97
|
-
动态效果为:
|
|
98
|
-
|
|
99
|
-

|
|
100
|
-
|
package/docs/zh/command/clean.md
DELETED
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
# Clean 命令
|
|
2
|
-
|
|
3
|
-
`clean`命令是清理 Serverless Devs 的缓存相关功能,可以通过该命令清理环境、不用的依赖包以及相关的缓存内容。
|
|
4
|
-
|
|
5
|
-
- [命令解析](#命令解析)
|
|
6
|
-
- [参数解析](#参数解析)
|
|
7
|
-
- [操作案例](#操作案例)
|
|
8
|
-
|
|
9
|
-
## 命令解析
|
|
10
|
-
|
|
11
|
-
当我们执行`s clean -h`之后,可以进行相关帮助信息的查看:
|
|
12
|
-
|
|
13
|
-
```shell script
|
|
14
|
-
$ s clean -h
|
|
15
|
-
Usage: s cli [options]
|
|
16
|
-
|
|
17
|
-
Clean up the cache related functions of serverless devs. You can clean up the environment, unused dependent packages and related cache contents through this command.
|
|
18
|
-
|
|
19
|
-
Example:
|
|
20
|
-
$ s clean --component fc-api
|
|
21
|
-
$ s clean --all
|
|
22
|
-
|
|
23
|
-
Tips:
|
|
24
|
-
Get all installed component: s component
|
|
25
|
-
|
|
26
|
-
📖 Document: https://github.com/Serverless-Devs/Serverless-Devs/tree/master/docs/zh/command/clean.md
|
|
27
|
-
|
|
28
|
-
Options:
|
|
29
|
-
--all Clean up the environment
|
|
30
|
-
--cache [dirName] Delete the <dirName> file in the cache
|
|
31
|
-
--component [componentName] Remove component (like: fc, fc@0.0.1)
|
|
32
|
-
-h, --help Display help for command
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
### 参数解析
|
|
36
|
-
|
|
37
|
-
| 参数全称 | 参数缩写 | 是否必填 | 参数含义 |
|
|
38
|
-
|-----|-----|-----|-----|
|
|
39
|
-
| all | | 选填 | 清理环境 |
|
|
40
|
-
| cache | | 选填 | 删除缓存里的的<dirName>文件 |
|
|
41
|
-
| component | | 选填 | 删除指定的组件,可以是组件名,也可以是[组件名@版本号] |
|
|
42
|
-
|
|
43
|
-
### 操作案例
|
|
44
|
-
|
|
45
|
-
如果想要清理掉某个组件,可以通过`--component`参数与具体的组件名进行清理,例如:
|
|
46
|
-
|
|
47
|
-
```shell script
|
|
48
|
-
$ s clean --component fc-api
|
|
49
|
-
Component [fc-api] has been cleaned up successfully.
|
|
50
|
-
```
|
|
51
|
-
|
|
52
|
-
如果想要清理整体环境,可以直接通过`--all`参数进行,例如:
|
|
53
|
-
|
|
54
|
-
```shell script
|
|
55
|
-
$ s clean --all
|
|
56
|
-
The environment of Serverless Devs has been cleaned up successfully.
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
## 注意事项
|
|
60
|
-
|
|
61
|
-
在进行指定组件的清理时,系统会按照指定的逻辑进行组件的清理:
|
|
62
|
-
1. 系统先会确定当前设置的 Registry 缓存中,存在的符合条件的组件,并进行清理;
|
|
63
|
-
2. 系统将会对系统的最终 Registry 缓存中(Github Registry),存在的符合条件的组件,并进行清理;
|