mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-08 08:53:51 +00:00
03d5389540
* Create docker-ci.yml * docker build * add build app * path changes * delete double workflow * update docker run template * cleanup * resolve wierd path issue * wrong path * again wrong path * rename docker releases * move styles population and change to function call * re-add old build pipeline * rename buld file * feractor init function * refactor: startDb to initAssets * refactor: startDB to initAssets * fix: docker.cjs building whole app * fix: docker environment * update docker paths * update: build command * cleanup * cleanup: commented code --------- Co-authored-by: Fabian Posenau <fabian@fphome.de>
141 lines
3.6 KiB
YAML
141 lines
3.6 KiB
YAML
name: Ontime build
|
|
|
|
on:
|
|
push:
|
|
# run when a tag is created
|
|
tags:
|
|
- '*'
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
build_mac:
|
|
runs-on: macos-latest
|
|
timeout-minutes: 20
|
|
env:
|
|
CI: ''
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Use Node.js
|
|
uses: actions/setup-node@v2
|
|
with:
|
|
node-version: '14.x'
|
|
|
|
# React
|
|
- name: React - Install dependencies
|
|
run: yarn install --frozen-lockfile --network-timeout 300000
|
|
working-directory: ./client
|
|
|
|
- name: React - Build project
|
|
run: yarn build
|
|
working-directory: ./client
|
|
|
|
# Node server
|
|
- name: Server - Install dependencies
|
|
run: yarn install --frozen-lockfile --production --network-timeout 300000
|
|
working-directory: ./server/src
|
|
|
|
# App
|
|
- name: Electron - Install dependencies
|
|
shell: bash
|
|
run: yarn install --frozen-lockfile --network-timeout 300000 && yarn setdb
|
|
working-directory: ./server
|
|
- name: Electron - Build app
|
|
run: yarn dist-mac
|
|
working-directory: ./server
|
|
|
|
# Release
|
|
- name: Release
|
|
uses: softprops/action-gh-release@v1
|
|
with:
|
|
files: ./server/dist/ontime-macOS.dmg
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
build_win:
|
|
runs-on: windows-latest
|
|
timeout-minutes: 20
|
|
env:
|
|
CI: ''
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Use Node.js
|
|
uses: actions/setup-node@v1
|
|
with:
|
|
node-version: '14.x'
|
|
|
|
# React
|
|
- name: React - Install dependencies
|
|
run: yarn install --frozen-lockfile --network-timeout 300000
|
|
working-directory: ./client
|
|
|
|
- name: React - Build project
|
|
run: yarn build
|
|
working-directory: ./client
|
|
|
|
# Node server
|
|
- name: Server - Install dependencies
|
|
run: yarn install --frozen-lockfile --production --network-timeout 300000
|
|
working-directory: ./server/src
|
|
|
|
# App
|
|
- name: Electron - Install dependencies
|
|
shell: bash
|
|
run: yarn install --frozen-lockfile --network-timeout 300000 && yarn setdb
|
|
working-directory: ./server
|
|
- name: Electron - Build app
|
|
run: yarn dist-win
|
|
working-directory: ./server
|
|
|
|
# Release
|
|
- name: Release
|
|
uses: softprops/action-gh-release@v1
|
|
with:
|
|
files: ./server/dist/ontime-win64.exe
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
build_linux:
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 20
|
|
env:
|
|
CI: ''
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Use Node.js
|
|
uses: actions/setup-node@v1
|
|
with:
|
|
node-version: '14.x'
|
|
|
|
# React
|
|
- name: React - Install dependencies
|
|
run: yarn install --frozen-lockfile --network-timeout 300000
|
|
working-directory: ./client
|
|
|
|
- name: React - Build project
|
|
run: yarn build
|
|
working-directory: ./client
|
|
|
|
# Node server
|
|
- name: Server - Install dependencies
|
|
run: yarn install --frozen-lockfile --production --network-timeout 300000
|
|
working-directory: ./server/src
|
|
|
|
# App
|
|
- name: Electron - Install dependencies
|
|
shell: bash
|
|
run: yarn install --frozen-lockfile --network-timeout 300000 && yarn setdb
|
|
working-directory: ./server
|
|
- name: Electron - Build app
|
|
run: yarn dist-linux
|
|
working-directory: ./server
|
|
|
|
# Release
|
|
- name: Release
|
|
uses: softprops/action-gh-release@v1
|
|
with:
|
|
files: ./server/dist/ontime-linux.AppImage
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |