Skip to content

chore: Github workflow name #21

chore: Github workflow name

chore: Github workflow name #21

Workflow file for this run

name: Build
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
build_frontend:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up nodejs
uses: actions/setup-node@v3
with:
node-version: current
- name: Install dependencies
run: |
corepack enable
corepack prepare pnpm@latest --activate
pnpm install
working-directory: frontend
- name: Build
run: |
npx browserslist@latest --update-db
pnpm build
working-directory: frontend
- name: Archive app artifacts
uses: actions/upload-artifact@v3
with:
name: frontend-dist
path: frontend/dist
build:
runs-on: ubuntu-latest
needs: build_frontend
strategy:
matrix:
goos: [linux]
goarch: [amd64]
env:
CGO_ENABLED: 0
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
GOARM: ${{ matrix.goarm }}
steps:
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.21
- name: Checkout
uses: actions/checkout@v3
- name: Download app artifacts
uses: actions/download-artifact@v3
with:
name: frontend-dist
path: frontend/dist
- name: Build
run: go build -o EmptyClassroom -v ./
- name: Archive app artifacts
uses: actions/upload-artifact@v3
with:
name: EmptyClassroom
path: EmptyClassroom