Add GitHub Actions workflow for Node.js build and deployment

This commit is contained in:
Rodrigo Rodriguez (Pragmatismo) 2025-04-12 19:02:46 -03:00
parent ce0ed49700
commit 760dc2bfd7

View file

@ -0,0 +1,33 @@
name: GBCI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: gbo
steps:
- name: Disable SSL verification (temporary)
run: git config --global http.sslVerify false
- uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- name: Install dependencies and build
run: |
pnpm i
pnpm run build
- name: Deploy to production
run: |
sudo rm -rf /opt/gbo/websites/docs.pragmatismo.com.br/*
sudo cp -r ./out/. /opt/gbo/websites/docs.pragmatismo.com.br/