Skip to content

更新 k8s 逻辑 #1751

更新 k8s 逻辑

更新 k8s 逻辑 #1751

Workflow file for this run

name: Build app and deploy
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: use Node.js 20.0.0
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install and Build
run: |
npm cache clean --force
npm install
npm run build
# 部署到阿里云
- name: Deploy to Aliyun
uses: easingthemes/ssh-deploy@v4.1.8
env:
SSH_PRIVATE_KEY: ${{ secrets.PRIVATE_KEY }}
ARGS: "-rlgoDzvc -i"
SOURCE: ".vuepress/dist/"
REMOTE_HOST: "110.40.229.45"
REMOTE_USER: "root"
TARGET: "/home/www/thebyte.com.cn"
SCRIPT_BEFORE: |
whoami
ls -al