diff --git a/.github/workflows/build-and-test/action.yaml b/.github/workflows/build-and-test/action.yaml index b202376..e06dfcb 100644 --- a/.github/workflows/build-and-test/action.yaml +++ b/.github/workflows/build-and-test/action.yaml @@ -78,9 +78,9 @@ runs: /home/${{ inputs.user }}/.pgrx key: pg_idkit-tests-pgrx-init-${{ inputs.rust-container-version }}-cargo-${{ runner.os }} - ############### - # Build/Tests # - ############### + ######### + # Setup # + ######### - name: Add idkit to group shell: bash @@ -96,6 +96,26 @@ runs: git config --global --add safe.directory /__w/pg_idkit/pg_idkit su idkit -c "git config --global --add safe.directory /__w/pg_idkit/pg_idkit" + + - name: Reinstall deps due to GLIBC issue + if: ${{ inputs.artifact-upload }} + shell: bash + env: + CARGO_HOME: ${{ inputs.cargo-home-dir }} + CARGO_TARGET_DIR: ${{ inputs.cargo-target-dir }} + SCCACHE_DIR: ${{ inputs.sccache-dir }} + CARGO_BUILD_RUSTC_WRAPPER: ${{ inputs.cargo-build-rustc-wrapper }} + CARGO_INCREMENTAL: ${{ inputs.cargo-env-incrmental }} + CARGO_PROFILE: ${{ inputs.cargo-profile }} + USER: ${{ inputs.user }} + PGRX_PKG_PATH_PREFIX: ${{ inputs.cargo-target-dir }} + run: | + su idkit -c "cargo install --force cargo-get cargo-edit" + + ############### + # Build/Tests # + ############### + # Initialize cargo-pgrx if necessary - name: Initialize cargo-pgrx shell: bash @@ -159,21 +179,6 @@ runs: # Artifacts # ############# - - name: Reinstall deps due to GLIBC issue - if: ${{ inputs.artifact-upload }} - shell: bash - env: - CARGO_HOME: ${{ inputs.cargo-home-dir }} - CARGO_TARGET_DIR: ${{ inputs.cargo-target-dir }} - SCCACHE_DIR: ${{ inputs.sccache-dir }} - CARGO_BUILD_RUSTC_WRAPPER: ${{ inputs.cargo-build-rustc-wrapper }} - CARGO_INCREMENTAL: ${{ inputs.cargo-env-incrmental }} - CARGO_PROFILE: ${{ inputs.cargo-profile }} - USER: ${{ inputs.user }} - PGRX_PKG_PATH_PREFIX: ${{ inputs.cargo-target-dir }} - run: | - su idkit -c "cargo install --force cargo-get cargo-edit" - # Run cargo test - name: Build a package if: ${{ inputs.artifact-upload }}