]> Repositorios git - scryer-prolog.git/commitdiff
fix ci and update all used actions
authorBennet Bleßmann <[email protected]>
Thu, 23 Jan 2025 18:53:59 +0000 (19:53 +0100)
committerBennet Bleßmann <[email protected]>
Thu, 23 Jan 2025 18:53:59 +0000 (19:53 +0100)
.github/actions/setup-rust/action.yml
.github/workflows/ci.yml
.github/workflows/docker-publish.yml

index 3495b6aaca14b501032ddd4b7b35a2048b309beb..6e6786c754854369866f94038cf0ca1793b2ca31 100644 (file)
@@ -33,7 +33,7 @@ runs:
       echo "CC=clang" >> $GITHUB_ENV
       echo "PKG_CONFIG_SYSROOT_DIR=/" >> $GITHUB_ENV
 
-  - uses: actions/cache@v3
+  - uses: actions/cache@v4
     with:
       path: |
         ~/.cargo/bin/
@@ -46,7 +46,7 @@ runs:
   # Remove build artifacts for the current crate, since it will be rebuilt every
   # run anyway, but keep dependency artifacts to cache them.
   # Must be placed after actions/cache so its post step runs first.
-  - uses: pyTooling/Actions/with-post-step@v0.4.6
+  - uses: pyTooling/Actions/with-post-step@v4.1.0
     with:
       main: bash ./.github/actions/setup-rust/cleanup.sh
       post: bash ./.github/actions/setup-rust/cleanup.sh
index 3fc66550dc4af06cab4589c3df4e497a7bab24fc..8e4f447d5153c084ca650c6bab3b57e539e7b106 100644 (file)
@@ -17,7 +17,7 @@ jobs:
   style:
     runs-on: ubuntu-22.04
     steps:
-      - uses: actions/checkout@v3
+      - uses: actions/checkout@v4
       - name: Setup Rust
         uses: ./.github/actions/setup-rust
         with:
@@ -55,7 +55,7 @@ jobs:
       run:
         shell: bash
     steps:
-      - uses: actions/checkout@v3
+      - uses: actions/checkout@v4
       - uses: actionhippie/swap-space@v1
         if: matrix.use_swap
         with:
@@ -88,7 +88,7 @@ jobs:
           echo "$PWD/target/release" >> $GITHUB_PATH
       - name: Publish release binary artifact
         if: matrix.publish
-        uses: actions/upload-artifact@v3
+        uses: actions/upload-artifact@v4
         with:
           path: target/${{ matrix.target }}/release/scryer-prolog*
           name: scryer-prolog_${{ matrix.os }}_${{ matrix.target }}
@@ -99,7 +99,7 @@ jobs:
     needs: [build-test]
     steps:
       # Download prebuilt ubuntu binary from build-test job, setup logtalk
-      - uses: actions/download-artifact@v3
+      - uses: actions/download-artifact@v4
         with:
           name: scryer-prolog_ubuntu-20.04_x86_64-unknown-linux-gnu
       - run: |
@@ -123,12 +123,12 @@ jobs:
             || echo "::warning ::logtalk compliance suite failed"
             # -u "https://github.com/LogtalkDotOrg/logtalk3/tree/$LOGTALK_GIT_HASH/tests/prolog/" \
       - name: Publish Logtalk test logs
-        uses: actions/upload-artifact@v3
+        uses: actions/upload-artifact@v4
         with:
           name: logtalk-test-logs
           path: '${{ env.LOGTALKUSER }}/tests/prolog/logtalk_tester_logs'
       - name: Publish Logtalk test results artifact
-        uses: actions/upload-artifact@v3
+        uses: actions/upload-artifact@v4
         with:
           name: logtalk-test-results
           path: '${{ env.LOGTALKUSER }}/tests/prolog/**/*.xml'
@@ -143,7 +143,7 @@ jobs:
   report:
     runs-on: ubuntu-22.04
     steps:
-      - uses: actions/checkout@v3
+      - uses: actions/checkout@v4
       - name: Setup Rust
         uses: ./.github/actions/setup-rust
         with:
@@ -162,7 +162,7 @@ jobs:
         run: |
           RUSTC_BOOTSTRAP=1 cargo test --all -- -Z unstable-options --format json --report-time | cargo2junit > cargo_test_results.xml
       - name: Publish cargo test results artifact
-        uses: actions/upload-artifact@v3
+        uses: actions/upload-artifact@v4
         with:
           name: cargo-test-results
           path: cargo_test_results.xml
@@ -181,7 +181,7 @@ jobs:
       - run: cargo bench --bench run_criterion -- --profile-time 60
 
       - name: Publish benchmark results
-        uses: actions/upload-artifact@v3
+        uses: actions/upload-artifact@v4
         with:
           name: benchmark-results
           path: |
@@ -195,7 +195,7 @@ jobs:
     needs: [build-test]
     if: startsWith(github.ref, 'refs/tags/v')
     steps:
-      - uses: actions/download-artifact@v3
+      - uses: actions/download-artifact@v4
       - name: Zip binaries for release
         run: |
           zip scryer-prolog_macos-11.zip ./scryer-prolog_macos-11_x86_64-apple-darwin/scryer-prolog
@@ -204,7 +204,7 @@ jobs:
           zip scryer-prolog_windows-latest.zip ./scryer-prolog_windows-latest_x86_64-pc-windows-msvc/scryer-prolog.exe
           zip scryer-prolog_wasm32.zip ./scryer-prolog_ubuntu-22.04_wasm32-unknown-unknown/scryer-prolog.wasm
       - name: Release
-        uses: softprops/action-gh-release@v1
+        uses: softprops/action-gh-release@v2
         with:
           files: |
             scryer-prolog_macos-11.zip
index dffe1cd7d9c8cf9983b6d45c93e5a9f5291a69e7..ae969be3dcfe7504d6ac579c34253859cf1eca3b 100644 (file)
@@ -14,17 +14,17 @@ jobs:
 
     steps:
       - name: Checkout repository
-        uses: actions/checkout@v3
+        uses: actions/checkout@v4
 
       # Workaround: https://github.com/docker/build-push-action/issues/461
       - name: Setup Docker buildx
         # https://github.com/docker/setup-buildx-action
-        uses: docker/setup-buildx-action@v2.2.1
+        uses: docker/setup-buildx-action@v3
 
       # Login against Docker registry
       - name: Log into registry
         # https://github.com/docker/login-action
-        uses: docker/login-action@v2.1.0
+        uses: docker/login-action@v3
         with:
           username: ${{ secrets.DOCKERHUB_USERNAME }}
           password: ${{ secrets.DOCKERHUB_TOKEN }}
@@ -35,7 +35,7 @@ jobs:
       - name: Extract Docker metadata
         id: meta
         # https://github.com/docker/metadata-action
-        uses: docker/metadata-action@v4.1.1
+        uses: docker/metadata-action@v5
         with:
           images: docker.io/${{ secrets.DOCKERHUB_USERNAME }}/scryer-prolog
           tags: |
@@ -47,7 +47,13 @@ jobs:
       - name: Build and push Docker image
         id: build-and-push
         # https://github.com/docker/build-push-action
-        uses: docker/[email protected]
+        uses: docker/build-push-action@v6
+        # v4 adds SLSA Provenance attestation which is 
+        # - unsupported by AWS Lambda 
+        # - limited support by Google Cloud Run 
+        #   > If deploying a multi-architecture image, the manifest list must include linux/amd64.
+        # see https://github.com/docker/build-push-action/releases/tag/v4.0.0
+        # we might want to disable this if its a problem for someone
         with:
           context: .
           push: true