Skip to content

Update

Update #118

Workflow file for this run

name: Rollup
on:
push:
branches: [ "deploy_testing" ]
jobs:
build_and_deploy:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x]
steps:
- uses: kachick/[email protected]
timeout-minutes: 15
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm install
- run: npm run build --if-present
- name: copy file via ssh password
uses: appleboy/scp-action@master
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
source: "./build/"
target: "/home/aukus/deploy_test_aukus_frontend/deploy_build"
- name: swap build and restart nginx
uses: appleboy/[email protected]
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
command_timeout: 1m
script: cd "/home/aukus/deploy_test_aukus_frontend/" && sudo systemctl stop nginx && rm -rf build && mv deploy_build/build ./ && sudo systemctl start nginx