Skip to content

Update main.yml

Update main.yml #4

Workflow file for this run

name: Build & deploy
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install Node.js
uses: actions/setup-node@v3
with:
node-version: 18
- name: Install NPM dependencies
run: npm install
- name: Run build task
run: npm run build
- name: Deploy
uses: easingthemes/[email protected]
env:
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
ARGS: "--delete"
REMOTE_HOST: ${{ secrets.REMOTE_HOST }}
REMOTE_USER: ${{ secrets.REMOTE_USER }}
TARGET: "/srv/53.asteriski.fi/"
EXCLUDE: "/node_modules/, /.git/"
SCRIPT_AFTER: |
pm2 restart 53v