From e5bddaa8b149d2ea514acf9dff1fef48ab42e1f6 Mon Sep 17 00:00:00 2001 From: Djuri Baars Date: Mon, 10 Jun 2024 13:11:10 +0200 Subject: [PATCH] Add linux build --- .github/workflows/build_linux.yaml | 39 ++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 .github/workflows/build_linux.yaml diff --git a/.github/workflows/build_linux.yaml b/.github/workflows/build_linux.yaml new file mode 100644 index 0000000..3f907c6 --- /dev/null +++ b/.github/workflows/build_linux.yaml @@ -0,0 +1,39 @@ +name: Build Linux artifacts + +on: workflow_dispatch + +jobs: + build-linux: + runs-on: + - ubuntu-latest + permissions: + contents: write + steps: + - name: Checkout repository + uses: actions/checkout@v4 + - name: Login to GitHub Container Registry + uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + - name: Cache Docker layers + uses: actions/cache@v4 + with: + path: /tmp/.buildx-cache + key: ${{ runner.os }}-buildx-${{ github.sha }} + restore-keys: | + ${{ runner.os }}-buildx- + - name: Run Docker Container + run: | + docker run --rm \ + --volume "${{ github.workspace }}:/src/" \ + --env SPECFILE=./BTClockOTA.spec \ + ghcr.io/btclock/pyinstaller-wxpython-linux:latest + - name: Archive artifacts + uses: actions/upload-artifact@v4 + with: + name: linux-artifacts + path: dist/