added admin routes #26
Workflow file for this run
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: Backend - Build & Deploy | |
on: | |
push: | |
branches: [ "main" ] | |
paths: "server/**" | |
pull_request: | |
branches: [ "main" ] | |
paths: "server/**" | |
jobs: | |
build-and-deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out repository | |
uses: actions/checkout@v4 | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '20' | |
- name: Install dependencies | |
working-directory: ./server | |
run: yarn install --frozen-lockfile | |
- name: Build server | |
working-directory: ./server | |
run: yarn build | |
- uses: a7ul/[email protected] | |
with: | |
command: c | |
cwd: "./" | |
files: | | |
server/ | |
outPath: deploy.tar | |
- name: Deploy App to CapRover | |
uses: caprover/[email protected] | |
with: | |
server: '${{ secrets.CAPROVER_SERVER }}' | |
app: '${{ secrets.APP_NAME }}' | |
token: '${{ secrets.APP_TOKEN }}' |