V2wip #397
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: Build | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [18.x] | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v3 | |
- name: Use Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Dependency install | |
run: | | |
npm install @ionic/cli@6.20.4 native-run@1.3.0 | |
npm install | |
- name: Build Storage Mirror | |
run: | | |
cd storage-mirror | |
npm install | |
npm run build | |
- name: Copy environment.ts to environment.prod.ts | |
run: | | |
cp src/environments/environment.ts src/environments/environment.prod.ts | |
- name: Build | |
run: | | |
./node_modules/@ionic/cli/bin/ionic build --prod --release | |
- name: Install Chrome | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y \ | |
wget \ | |
fonts-liberation \ | |
libatk-bridge2.0-0 \ | |
libatk1.0-0 \ | |
libatspi2.0-0 \ | |
libcups2 \ | |
libdbus-1-3 \ | |
libdrm2 \ | |
libgbm1 \ | |
libgtk-3-0 \ | |
libnspr4 \ | |
libnss3 \ | |
libwayland-client0 \ | |
libxcomposite1 \ | |
libxdamage1 \ | |
libxfixes3 \ | |
libxkbcommon0 \ | |
libxrandr2 \ | |
xdg-utils \ | |
libu2f-udev \ | |
libvulkan1 | |
sudo apt-get install -y --no-install-recommends libasound2 || sudo apt-get install -y libasound2t64 | |
wget -q https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb | |
sudo apt-get install -y ./google-chrome-stable_current_amd64.deb | |
- name: Test | |
run: ./node_modules/@angular/cli/bin/ng.js test --no-watch --no-progress --browsers=ChromeHeadlessCI |