Former-commit-id: 3293e654b1829ccd23963d7d4d15a936c3812649 Former-commit-id: 0eb62b066dad6687cdc8710f6816196359e3cecc Former-commit-id: ad8327a57c68a3506c629a3cdc02235fdcdb92b8 Former-commit-id: 7dbad5973d622fc0b704a4b4c632cb9b4dda05ed [formerly af58bde65d392946beb0efecff4207063fd7f775] Former-commit-id: 560f35c9cb694da03f4cdc8a8ecf3666e5523fe5 Former-commit-id: 4b10557b4fd0712297e19ea5d4fa4ea90232b2d8 Former-commit-id: 403b10c5ff48f4a759cffb0e3a91615cf536ea4a Former-commit-id: 262e0bb7009afba35f4b16dad3c99375b2623fbd Former-commit-id: 9f64293717d3e98f06396be890641f250e1aa14f
29 lines
747 B
YAML
29 lines
747 B
YAML
name: Build and upload to qiniu CDN
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
|
|
jobs:
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v1
|
|
- uses: actions/setup-node@v1
|
|
with:
|
|
node-version: '10.x'
|
|
- name: Install packages
|
|
run: npm i
|
|
- name: Build Code
|
|
run: npm run build:github
|
|
- name: Deploy to CDN
|
|
run: |
|
|
dist=$GITHUB_WORKSPACE/dist
|
|
prefix=d2-admin/preview/
|
|
bucket=fairyever-site
|
|
./deploy/qshell account ${{ secrets.AK }} ${{ secrets.SK }} liyang
|
|
./deploy/qshell qupload2 --src-dir=$dist --bucket=$bucket --key-prefix=$prefix --overwrite=true --rescan-local=true
|
|
./deploy/qshell cdnrefresh --dirs -i ./deploy/cdnrefresh.txt |