diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c083f15..4b4eda7 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -26,7 +26,39 @@ jobs: password: ${{ secrets.DOCKER_PASSWORD }} if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} - run: make UBUNTU=${{ matrix.ubuntu-version }} push - if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} + if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} + + build-ds: + name: Build Driver Station + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - run: make update/ds + - run: make build/ds + - name: Log in to docker + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} + - run: make push/ds + if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} + + build-arm-ds: + name: Build Driver Station Arm + runs-on: ubuntu-24.04-arm + steps: + - uses: actions/checkout@v4 + - run: make update/armds + - run: make build/armds + - name: Log in to docker + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} + - run: make push/armds + if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} build-arm: name: Build ARM @@ -46,7 +78,7 @@ jobs: password: ${{ secrets.DOCKER_PASSWORD }} if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} - run: make UBUNTU=${{ matrix.debian-version }} push/arm-base - if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} + if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/main' }} build-minimal: name: Build Minimal diff --git a/Makefile b/Makefile index f9bbb9a..e723bbb 100644 --- a/Makefile +++ b/Makefile @@ -2,6 +2,8 @@ UBUNTU?=22.04 OPENSDK_UBUNTU?=20.04 DEBIAN?=bookworm +DS?=trixie + DOCKER_USER?=wpilib .PHONY: usage update update/arm push build \ @@ -93,3 +95,23 @@ save/minimal-cross: docker save ${DOCKER_USER}/raspbian-cross-ubuntu-minimal:bookworm-${UBUNTU} | zstd > raspbian.tar.zst include cross-ubuntu-py/py.mk + +update/ds: + docker pull docker.io/debian:${DS} + +build/ds: + cd driverstation-base && \ + docker build -t ${DOCKER_USER}/driverstation-base:x64 -f Dockerfile.x64 . + +push/ds: + docker push ${DOCKER_USER}/driverstation-base:x64 + +update/armds: + docker pull docker.io/arm64v8/debian:${DS} + +build/armds: + cd driverstation-base && \ + docker build -t ${DOCKER_USER}/driverstation-base:arm64 -f Dockerfile.arm64 . + +push/armds: + docker push ${DOCKER_USER}/driverstation-base:arm64 diff --git a/driverstation-base/Dockerfile.arm64 b/driverstation-base/Dockerfile.arm64 new file mode 100644 index 0000000..fd1c3ca --- /dev/null +++ b/driverstation-base/Dockerfile.arm64 @@ -0,0 +1,31 @@ +FROM arm64v8/debian:trixie + +RUN apt-get update && apt-get install -y apt-transport-https \ + ca-certificates \ + gnupg \ + tzdata \ + build-essential \ + ca-certificates \ + cmake \ + curl \ + fakeroot \ + g++ --no-install-recommends \ + gcc \ + gdb \ + gfortran \ + git \ + libc6-dev \ + make \ + sudo \ + unzip \ + wget \ + zip \ + ninja-build \ + libusb-1.0-0-dev \ + libudev-dev \ + libinput-dev \ + libavahi-client-dev \ + libavahi-common-dev \ + libicu-dev + +WORKDIR / diff --git a/driverstation-base/Dockerfile.x64 b/driverstation-base/Dockerfile.x64 new file mode 100644 index 0000000..af2d5df --- /dev/null +++ b/driverstation-base/Dockerfile.x64 @@ -0,0 +1,31 @@ +FROM debian:trixie + +RUN apt-get update && apt-get install -y apt-transport-https \ + ca-certificates \ + gnupg \ + tzdata \ + build-essential \ + ca-certificates \ + cmake \ + curl \ + fakeroot \ + g++ --no-install-recommends \ + gcc \ + gdb \ + gfortran \ + git \ + libc6-dev \ + make \ + sudo \ + unzip \ + wget \ + zip \ + ninja-build \ + libusb-1.0-0-dev \ + libudev-dev \ + libinput-dev \ + libavahi-client-dev \ + libavahi-common-dev \ + libicu-dev + +WORKDIR /