Skip to content
This repository has been archived by the owner on Oct 27, 2024. It is now read-only.

Update webpack.yml

Update webpack.yml #7

Workflow file for this run

name: NodeJS with Webpack
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
build:
runs-on: self-hosted
env:
ENV_FILE: ${{ vars.MASTER_ENV_FILE }}
USER: github-runner
HOST: ${{ vars.HOST }}
PROJECT_PATH: /var/www/kw-dex
strategy:
matrix:
node-version: [18.x]
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Generate env for project
run: echo "$ENV_FILE" >> .env
- name: Build
run: |
npm install
npm run typechain
npm run build
- name: Deploy static build to server
run: rsync -ar --delete-after ./dist/ ${USER?}@${HOST?}:${PROJECT_PATH?}/