This repository has been archived by the owner on Oct 10, 2024. It is now read-only.
Update server #12
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: CI | |
run-name: Update server | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
update-vps: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Update | |
uses: appleboy/[email protected] | |
with: | |
host: ${{ secrets.HOST }} | |
username: ubuntu | |
key: ${{ secrets.SSH_KEY }} | |
port: 22 | |
script: | | |
export NODE_OPTIONS=--max-old-space-size=8192 | |
cd /home/ubuntu/ephemeral | |
git pull | |
pnpm i | |
/home/ubuntu/.local/share/pnpm/pm2 stop ephemeral | |
pnpm build | |
/home/ubuntu/.local/share/pnpm/pm2 start ephemeral |