Skip to content

chore: temporarily change cdnjs endpoint to cdnjs.loli.net #90

chore: temporarily change cdnjs endpoint to cdnjs.loli.net

chore: temporarily change cdnjs endpoint to cdnjs.loli.net #90

Workflow file for this run

name: Deploy
on:
push:
branches:
- master
workflow_dispatch:
jobs:
deploy:
name: Build & Deploy
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: actions/cache@v2
with:
path: '**/node_modules'
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}-${{ hashFiles('patches/**') }}
- name: Use Node.js 16
uses: actions/setup-node@v2
with:
node-version: 16
cache: yarn
- name: Install Dependencies
run: yarn install
- name: Build Site
run: yarn build
env:
VITE_BAOSHUO_CDNJS: true
- name: Deploy site to server (Tokyo, JP)
uses: easingthemes/[email protected]
env:
ARGS: '-avz --delete'
SOURCE: dist/
REMOTE_HOST: ${{ secrets.REMOTE_HOST }}
REMOTE_USER: ${{ secrets.REMOTE_USER }}
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
TARGET: ${{ secrets.REMOTE_PATH }}
EXCLUDE: .git,.github,.gitlab-ci.yml,.nojekyll
- name: Deploy site to server (Hong Kong, CN)
uses: easingthemes/[email protected]
env:
ARGS: '-avz --delete'
SOURCE: dist/
REMOTE_HOST: ${{ secrets.REMOTE_HOST_2 }}
REMOTE_USER: ${{ secrets.REMOTE_USER }}
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
TARGET: ${{ secrets.REMOTE_PATH }}
EXCLUDE: .git,.github,.gitlab-ci.yml,.nojekyll