1- name : ' CI VM'
2- description : ' Run main CI steps in VMs for VM-only platforms.'
1+ name : " CI VM"
2+ description : " Run main CI steps in VMs for VM-only platforms."
33
44inputs :
55 working-directory :
6- description : ' Working directory.'
7- default : ' . '
6+ description : " Working directory."
7+ default : " . "
88 platform :
9- description : ' Platform to run the checks on.'
10- default : ' '
9+ description : " Platform to run the checks on."
10+ default : " "
1111 codecov-token :
12- description : ' Codecov token, if Codecov upload is desired.'
13- default : ' '
12+ description : " Codecov token, if Codecov upload is desired."
13+ default : " "
1414
1515runs :
1616 using : composite
@@ -27,14 +27,14 @@ runs:
2727 set -ex
2828 pwd
2929 case "$PLATFORM" in
30- freebsd) pkg install -y curl llvm nss pkgconf
30+ freebsd) pkg update -f && pkg install -y curl llvm nss pkgconf
3131 ;;
3232 openbsd) # TODO: Is there a way to not pin the version of llvm? -z to pkg_add does not work.
3333 pkg_add rust rust-clippy rust-rustfmt llvm-21.1.2p0 nss # rustup does not support OpenBSD at all
3434 ;;
35- netbsd) /usr/sbin/pkg_add pkgin && pkgin -y install curl clang nss pkgconf
35+ netbsd) /usr/sbin/pkg_add pkgin && pkgin -y update && pkgin -y install curl clang nss pkgconf
3636 ;;
37- solaris) pkg install clang-libs nss pkg-config
37+ solaris) pkg refresh && pkg install clang-libs nss pkg-config
3838 ;;
3939 *) echo "Unsupported OS: $PLATFORM"
4040 exit 1
@@ -53,30 +53,28 @@ runs:
5353 cd "$WD"
5454 pwd
5555 case "$PLATFORM" in
56- freebsd) sh rustup.sh --default-toolchain stable --profile minimal --component clippy,llvm-tools,rustfmt -y
57- . "\$HOME/.cargo/env"
58- ;;
5956 openbsd) export LIBCLANG_PATH=/usr/local/llvm21/lib
6057 export LLVM_COV=/usr/local/llvm21/bin/llvm-cov
6158 export LLVM_PROFDATA=/usr/local/llvm21/bin/llvm-profdata
62- [ "$WORKSPACE" ] && EXCLUDE="--exclude fuzz" # Fuzzing not supported on OpenBSD
6359 ;;
64- netbsd) sh rustup.sh --default-toolchain stable --profile minimal --component clippy,llvm-tools,rustfmt -y
60+ *) sh rustup.sh --default-toolchain stable --profile minimal --component clippy,llvm-tools,rustfmt -y
6561 . "\$HOME/.cargo/env"
66- # FIXME: Why do we need to set this on NetBSD?
62+ ;;
63+ esac
64+ case "$PLATFORM" in
65+ netbsd) # FIXME: Why do we need to set this on NetBSD?
6766 export LD_LIBRARY_PATH=/usr/pkg/lib/nss:/usr/pkg/lib/nspr
68- [ "$WORKSPACE" ] && EXCLUDE="--exclude fuzz" # Fuzzing not supported on NetBSD
6967 ;;
70- solaris) curl --output rust.sh -s https://raw.githubusercontent.com/psumbera/solaris-rust/refs/heads/main/sh.rust-web-install
71- chmod a+x rust.sh
72- ls -lt
73- source ./rust.sh || true # This does not exit with zero on success
74- export LIBCLANG_PATH="/usr/lib/amd64"
75- [ "$WORKSPACE" ] && EXCLUDE="--exclude fuzz" # Fuzzing not supported on Solaris
68+ solaris) export LIBCLANG_PATH="/usr/lib/amd64"
69+ ;;
70+ esac
71+ case "$PLATFORM" in
72+ freebsd) ;;
73+ *) [ "$WORKSPACE" ] && EXCLUDE="--exclude fuzz" # Fuzzing not supported on this platform
7674 ;;
7775 esac
7876 cargo version
79- cargo check --locked --all-targets $WORKSPACE \$EXCLUDE
77+ cargo check --locked --all-targets $WORKSPACE \${ EXCLUDE:-}
8078 case "$PLATFORM" in
8179 openbsd) # clippy fails on OpenBSD, because libfuzzer-sys is not supported.
8280 ;;
@@ -105,7 +103,7 @@ runs:
105103 echo "envs=CARGO_TERM_COLOR RUST_BACKTRACE RUST_LOG RUST_TEST_TIME_UNIT RUST_TEST_TIME_INTEGRATION RUST_TEST_TIME_DOCTEST WD" >> "$GITHUB_OUTPUT"
106104
107105 - if : ${{ inputs.platform == 'freebsd' }}
108- uses : vmactions/freebsd-vm@ba6bedee4a4884da2b782a41a64329a1c8e42ffb # v1.3.8
106+ uses : vmactions/freebsd-vm@4807432c7cab1c3f97688665332c0b932062d31f # v1.4.3
109107 with :
110108 usesh : true
111109 disable-cache : true
@@ -114,7 +112,7 @@ runs:
114112 run : ${{ steps.prep.outputs.run }}
115113
116114 - if : ${{ inputs.platform == 'openbsd' }}
117- uses : vmactions/openbsd-vm@f5b9bc1261c3d4eed9639fcae0cf5dcc5374ca0c # v1.3.2
115+ uses : vmactions/openbsd-vm@3fafb45f2e2e696249c583835939323fe1c3448c # v1.3.7
118116 with :
119117 usesh : true
120118 disable-cache : true
@@ -123,7 +121,7 @@ runs:
123121 run : ${{ steps.prep.outputs.run }}
124122
125123 - if : ${{ inputs.platform == 'netbsd' }}
126- uses : vmactions/netbsd-vm@37b614756f0b44b02f5dab4fd9ecb27545d1785e # v1.3.2
124+ uses : vmactions/netbsd-vm@ca7ff0556959998c82761c34ea0c3c99fa084c48 # v1.3.7
127125 with :
128126 usesh : true
129127 disable-cache : true
@@ -132,7 +130,7 @@ runs:
132130 run : ${{ steps.prep.outputs.run }}
133131
134132 - if : ${{ inputs.platform == 'solaris' }}
135- uses : vmactions/solaris-vm@37d40b6627e80434541454b42841caa4cc77d0cf # v1.2.7
133+ uses : vmactions/solaris-vm@0a231b94365d1911cf62097ef342f6b30d95598f # v1.3.2
136134 with :
137135 release : " 11.4-gcc"
138136 usesh : true
@@ -148,7 +146,7 @@ runs:
148146 run : test -f "$WORKING_DIR/codecov.json" && echo "exists=true" >> "$GITHUB_OUTPUT" || true
149147
150148 - if : ${{ steps.check-coverage.outputs.exists == 'true' }}
151- uses : codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
149+ uses : codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6.0.0
152150 with :
153151 files : codecov.json
154152 working-directory : ${{ inputs.working-directory }}
0 commit comments