Skip to content
Snippets Groups Projects
Unverified Commit 6653f42d authored by Ariya Hidayat's avatar Ariya Hidayat Committed by GitHub
Browse files

GitHub Actions CI to build and archive Uberjar (#13996)

* Collapse the build commands
* Set the env var INTERACTIVE to false
* Group dependency and build steps properly
* Add more paths to ignore
parent 498c8618
Branches
Tags
No related merge requests found
name: Uberjar
on:
push:
branches:
- master
- 'release-**'
paths-ignore:
- 'docs/**'
- 'frontend/test/**'
- 'enterprise/frontend/test/**'
jobs:
build:
runs-on: ubuntu-20.04
timeout-minutes: 60
strategy:
matrix:
edition: [ee, oss]
env:
MB_EDITION: ${{ matrix.edition }}
INTERACTIVE: false
steps:
- uses: actions/checkout@v2
- name: Prepare Node.js
uses: actions/setup-node@v1
with:
node-version: 14.x
- name: Prepare JDK 8
uses: actions/setup-java@v1
with:
java-version: 8
- name: Install gettext
run: sudo apt install gettext
- name: Install Clojure CLI
run: |
curl -O https://download.clojure.org/install/linux-install-1.10.1.708.sh &&
sudo bash ./linux-install-1.10.1.708.sh
- name: Check versions
run: |
echo "Node.js `node --version`"
echo "yarn `yarn --version`"
java -version
echo "Clojure `clojure -e "(println (clojure-version))"`"
lein --version
msgfmt --version
- name: Get yarn cache
uses: actions/cache@v2
with:
path: ~/.cache/yarn
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
- name: Get M2 cache
uses: actions/cache@v2
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/project.clj') }}-${{ hashFiles('**/deps.edn') }}
- run: yarn install --lockfile
- run: lein with-profile +include-all-drivers,+cloverage,+junit,+${{ matrix.edition }} deps
- run: ./bin/build
- name: Mark with the commit hash
run: git rev-parse --short HEAD > COMMIT-ID
- name: Calculate SHA256 checksum
run: sha256sum ./target/uberjar/metabase.jar > SHA256.sum
- name: Upload JARs as artifact
uses: actions/upload-artifact@v2
with:
name: metabase-${{ matrix.edition }}-uberjar
path: |
./target/uberjar/metabase.jar
./COMMIT-ID
./SHA256.sum
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment