-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds release CI and modifies existing build tooling (#264)
This change adds new tooling to "release" built executables via GitHub Actions and GitHub Release. This change also refactors existing build tooling to accommodate the following: - Changes the executable name to include the version identifier. - Changes the structure of the bin directory. - Reduces duplicate GitHub Action workflows via workflow calls. - Changes Docker image cache strategy to use the GHA backend. - Refactors the Dockerfile to use Ubuntu for CI. - Isolates Cypress tooling in `./test/cy.` - Isolates Bats tooling in `./test/bats.` - Fixes various issues in Justfiles to properly work in Docker. - Defaults the env `DOCKER` variable to false when env `CI` is false.
- Loading branch information
Showing
53 changed files
with
3,344 additions
and
5,041 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 @@ | ||
* |
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,32 @@ | ||
name: Agent | ||
on: | ||
workflow_call: | ||
jobs: | ||
agent: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: crazy-max/ghaction-github-runtime@v3 | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: extractions/setup-just@v1 | ||
- uses: docker/setup-qemu-action@v3 | ||
- uses: docker/setup-buildx-action@v3 | ||
- uses: actions/cache@v3 | ||
with: | ||
path: var-cache-apt | ||
key: var-cache-apt-${{ hashFiles('./build/ci/Dockerfile') }} | ||
- uses: reproducible-containers/[email protected] | ||
with: | ||
cache-source: var-cache-apt | ||
cache-target: /var/cache/apt | ||
- uses: actions/cache@v3 | ||
with: | ||
path: var-lib-apt | ||
key: var-lib-apt-${{ hashFiles('./build/ci/Dockerfile') }} | ||
- uses: reproducible-containers/[email protected] | ||
with: | ||
cache-source: var-lib-apt | ||
cache-target: /var/lib/apt | ||
- run: just lint | ||
- run: just test |
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,57 @@ | ||
name: Bats | ||
on: | ||
workflow_call: | ||
jobs: | ||
native: | ||
env: | ||
DOCKER: false | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
runner: [macos-latest, windows-latest, ubuntu-latest] | ||
runs-on: ${{ matrix.runner }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: extractions/setup-just@v1 | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: executables | ||
path: bin | ||
- run: chmod -R +x ./bin | ||
- run: just bats | ||
docker: | ||
env: | ||
DOCKER: true | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: crazy-max/ghaction-github-runtime@v3 | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: extractions/setup-just@v1 | ||
- uses: docker/setup-qemu-action@v3 | ||
- uses: docker/setup-buildx-action@v3 | ||
- uses: actions/cache@v3 | ||
with: | ||
path: var-cache-apt | ||
key: var-cache-apt-${{ hashFiles('./build/ci/Dockerfile') }} | ||
- uses: reproducible-containers/[email protected] | ||
with: | ||
cache-source: var-cache-apt | ||
cache-target: /var/cache/apt | ||
- uses: actions/cache@v3 | ||
with: | ||
path: var-lib-apt | ||
key: var-lib-apt-${{ hashFiles('./build/ci/Dockerfile') }} | ||
- uses: reproducible-containers/[email protected] | ||
with: | ||
cache-source: var-lib-apt | ||
cache-target: /var/lib/apt | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: executables | ||
path: bin | ||
- run: chmod -R +x ./bin | ||
- run: just bats |
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,40 @@ | ||
name: Build | ||
env: | ||
MODE: prod | ||
on: | ||
workflow_call: | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: crazy-max/ghaction-github-runtime@v3 | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: extractions/setup-just@v1 | ||
- uses: docker/setup-qemu-action@v3 | ||
- uses: docker/setup-buildx-action@v3 | ||
- uses: actions/cache@v3 | ||
with: | ||
path: var-cache-apt | ||
key: var-cache-apt-${{ hashFiles('./build/ci/Dockerfile') }} | ||
- uses: reproducible-containers/[email protected] | ||
with: | ||
cache-source: var-cache-apt | ||
cache-target: /var/cache/apt | ||
- uses: actions/cache@v3 | ||
with: | ||
path: var-lib-apt | ||
key: var-lib-apt-${{ hashFiles('./build/ci/Dockerfile') }} | ||
- uses: reproducible-containers/[email protected] | ||
with: | ||
cache-source: var-lib-apt | ||
cache-target: /var/lib/apt | ||
- run: just web install | ||
- run: just web build | ||
- run: just build | ||
- uses: actions/upload-artifact@v3 | ||
id: upload | ||
with: | ||
name: executables | ||
path: bin/**/* |
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,23 @@ | ||
name: Cypress | ||
on: | ||
workflow_call: | ||
jobs: | ||
native: | ||
env: | ||
DOCKER: false | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [macos-latest, windows-latest, ubuntu-latest] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: extractions/setup-just@v1 | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: executables | ||
path: bin | ||
- run: chmod -R +x ./bin | ||
- run: just cy |
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,18 @@ | ||
name: Extensions | ||
on: | ||
workflow_call: | ||
jobs: | ||
jupyterlab: | ||
env: | ||
DOCKER: false | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: extractions/setup-just@v1 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.11' | ||
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1 | ||
- run: just jupyterlab install | ||
- run: just jupyterlab lint | ||
- run: just jupyterlab test |
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,31 @@ | ||
name: Image | ||
on: | ||
workflow_call: | ||
jobs: | ||
image: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: crazy-max/ghaction-github-runtime@v3 | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: extractions/setup-just@v1 | ||
- uses: docker/setup-qemu-action@v3 | ||
- uses: docker/setup-buildx-action@v3 | ||
- uses: actions/cache@v3 | ||
with: | ||
path: var-cache-apt | ||
key: var-cache-apt-${{ hashFiles('./build/ci/Dockerfile') }} | ||
- uses: reproducible-containers/[email protected] | ||
with: | ||
cache-source: var-cache-apt | ||
cache-target: /var/cache/apt | ||
- uses: actions/cache@v3 | ||
with: | ||
path: var-lib-apt | ||
key: var-lib-apt-${{ hashFiles('./build/ci/Dockerfile') }} | ||
- uses: reproducible-containers/[email protected] | ||
with: | ||
cache-source: var-lib-apt | ||
cache-target: /var/lib/apt | ||
- run: just image |
Oops, something went wrong.