-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'github-actions' into 'master'
Build wire dashboard using github actions See merge request public-resolume/wire-dashboard!2
- Loading branch information
Showing
2 changed files
with
29 additions
and
45 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: npm build | ||
|
||
on: | ||
push | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Use nodejs | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: '20.x' | ||
- name: Install dependencies | ||
run: npm install | ||
- name: Compile project | ||
run: npm run build | ||
env: | ||
PUBLIC_URL: '/api/docs/dashboard' | ||
- name: Upload compiled build | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: wire-dashboard build | ||
path: build |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,8 @@ | ||
image: node:lts | ||
|
||
cache: | ||
paths: | ||
- node_modules/ | ||
|
||
before_script: | ||
- npm install | ||
image: gitlab.resolume.com:4567/resolume/containers/github-actions/act:latest | ||
|
||
build: | ||
tags: | ||
- docker | ||
stage: build | ||
script: | ||
- npm run build | ||
except: | ||
- master | ||
- tags | ||
|
||
bundle: | ||
variables: | ||
PUBLIC_URL: "/api/docs/dashboard" # the path our built-in wire webserver will serve this as | ||
tags: | ||
- docker | ||
stage: build | ||
script: | ||
- npm run build | ||
artifacts: | ||
paths: | ||
- build | ||
only: | ||
- master | ||
- tags | ||
|
||
pages: | ||
variables: | ||
PUBLIC_URL: "/${CI_PROJECT_NAME}" # slash is important | ||
tags: | ||
- docker | ||
stage: build | ||
script: | ||
- npm run build | ||
- rm -rf publis | ||
- mv build public | ||
- cp public/index.html public/404.html | ||
artifacts: | ||
paths: | ||
- public # this is what gitlab pages expects | ||
only: | ||
- master | ||
- tags | ||
- act |