forked from hi-our/hi-face
-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (32 loc) · 1.35 KB
/
cloudbase-development.yml
File metadata and controls
39 lines (32 loc) · 1.35 KB
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
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
### Web云开发的部署命令 https://github.com/TencentCloudBase/cloudbase-action
name: deploy-cloudbase-development
on:
push:
branches: [ deploy/cloudbase-development ] # push到该分支后触发action
pull_request:
branches: [ deploy/cloudbase-development ] # pr到该分支后触发action
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [10.x, 12.x]
steps:
- uses: actions/checkout@v2 # 拉取最新代码
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: cd taro/
- run: npm i
- run: npm run release:yzweb --if-present # 编译代码
- name: Deploy static to Tencent CloudBase # 部署到腾讯云云开发cloudBase的静态网站托管上
id: deployStatic
uses: TencentCloudBase/cloudbase-action@v1.1.0
with:
secretId: ${{ secrets.SECRET_ID }}
secretKey: ${{ secrets.SECRET_KEY }}
envId: ${{ secrets.ENV_ID_DEVELOPMENT }} # 注意环境ID为开发环境
staticSrcPath: taro/dist-h5/