Merge pull request #10 from wsg815/master #27
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: Bulid and Deploy | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
jobs: | |
Bulid-and-Deploy: | |
runs-on: ubuntu-latest | |
env: | |
NODE_VERSION: '16' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
- name: Install dependencies | |
run: npm install | |
- name: Build documentation site | |
run: npm run docs:build | |
- name: Deploy | |
uses: easingthemes/ssh-deploy@main | |
env: | |
SSH_PRIVATE_KEY: ${{ secrets.ACCESS_TOKEN }} | |
ARGS: "-rltgoDzvO --delete" | |
SOURCE: "/docs/.vuepress/dist/" | |
REMOTE_HOST: "${{ secrets.SERVER_HOST }}" | |
REMOTE_USER: "${{ secrets.USER_NAME }}" | |
TARGET: "/usr/local/nginx/html/justlaws" |