remove base #8
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: Deploy to OSS | |
on: | |
push: | |
branches: | |
- master # 替换为你的默认分支 | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 18 | |
- name: Build VitePress | |
run: | | |
npm install | |
npm run docs:build | |
echo 'element.hackslog.com' > docs/.vitepress/dist/CNAME | |
ls | |
- name: Upload files to OSS | |
uses: jievince/[email protected] | |
with: | |
key-id: ${{ secrets.ALIYUN_OSS_ACCESS_KEY_ID }} | |
key-secret: ${{ secrets.ALIYUN_OSS_ACCESS_KEY_SECRET }} | |
region: oss-cn-guangzhou | |
bucket: ${{ secrets.ALIYUN_OSS_BUCKET }} | |
asset-path: docs/.vitepress/dist/ | |
target-path: / |