From 5e83acf5bd2693421c9909554723d605b1247cad Mon Sep 17 00:00:00 2001 From: fx Date: Mon, 9 Oct 2023 21:52:06 +0200 Subject: try arm comp and ghcr --- .github/workflows/test.yml | 34 +++++++++++++++++++++++----------- 1 file changed, 23 insertions(+), 11 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 4b098de..c1bfdf7 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,12 +12,11 @@ env: RUSTC_WRAPPER: "sccache" SQLX_OFFLINE: "true" CARGO_TERM_COLOR: always + CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABIHF_LINKER: arm-linux-gnueabihf-gcc jobs: build: - runs-on: ubuntu-latest - steps: - name: Run sccache-cache uses: mozilla-actions/sccache-action@v0.0.3 @@ -26,20 +25,33 @@ jobs: - uses: actions-rs/toolchain@v1 with: toolchain: stable + target: armv7-unknown-linux-gnueabihf components: rustfmt, clippy override: true - - name: Run cargo test - uses: actions-rs/cargo@v1 - with: - command: test + - name: Install arm linker + run: sudo apt update && sudo apt install gcc-arm-linux-gnueabihf -y - - name: Run cargo check + - name: Cargo build uses: actions-rs/cargo@v1 with: - command: check + command: build + args: --release --target armv7-unknown-linux-gnueabihf - - name: Run cargo clippy - uses: actions-rs/cargo@v1 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + - name: Login to DockerHub + uses: docker/login-action@v2 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Build and push + id: docker_build + uses: docker/build-push-action@v3 with: - command: clippy + file: Dockerfile + push: true + tags: | + ghcr.io/fxqnlr/webol:dev-latest + ghcr.io/fxqnlr/webol:dev-${{ github.run_number }} \ No newline at end of file -- cgit v1.2.3