diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000000..0c5ac2a4cb --- /dev/null +++ b/.dockerignore @@ -0,0 +1,2 @@ +/target +/guide diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1a80756b7d..a1ba9c28f8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -11,6 +11,10 @@ env: # increment this manually to force cache eviction RUST_CACHE_PREFIX: "v0-rust" +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/master' }} + jobs: lint: name: Lint diff --git a/.github/workflows/docsrs_bindings.yml b/.github/workflows/docsrs_bindings.yml new file mode 100644 index 0000000000..832b3e65dc --- /dev/null +++ b/.github/workflows/docsrs_bindings.yml @@ -0,0 +1,28 @@ +name: docsrs bindings +on: + pull_request: + paths: + - 'allowed-bindings.rs' + - 'docsrs_bindings.rs' + - 'Cargo.toml' + - 'build.rs' + - 'Dockerfile' + - '.dockerignore' + - 'tools/update_bindings.sh' + - '.github/workflows/docsrs_bindings.yml' + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + lint-bindings: + name: Lint bindings + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: Check docsrs_bindings.rs + run: tools/update_bindings.sh && git diff --exit-code docsrs_bindings.rs diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000000..030cddac2a --- /dev/null +++ b/Dockerfile @@ -0,0 +1,39 @@ +FROM rust:latest AS base +ARG PHP_VERSION=8.4 +WORKDIR /tmp +RUN <