seata website deploy on oss #738
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: seata.io deploy on oss | |
on: | |
push: | |
branches: | |
- docusaurus | |
#This schedule only takes effect in the default branch | |
schedule: | |
- cron: '0 */12 * * *' | |
jobs: | |
Build-Deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
- name: Use Node.js 18.x | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 18.x | |
- name: Build | |
run: | | |
npm install && npm run build && mkdir deploy-dist && cp -R build/* deploy-dist/ && mv build .htaccess *.txt *.xml deploy-dist/ | |
- name: Use Node.js 12.x | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 12.x | |
- run: npm i @serverless-devs/s -g --registry=https://registry.npmmirror.com | |
- run: s config add --AccountID ${{secrets.ACCOUNT_ID}} --AccessKeyID ${{secrets.ACCESS_KEYID}} --AccessKeySecret ${{secrets.ACCESS_KEYSECRET}} -a seata -f | |
- name: Deploy | |
run: s deploy --use-local -y |