CI: Linux tests in the Gitea job's image, since the hosted image's zsh and fish break the shell tests
This commit is contained in:
2 files changed
+13
-3
No files matched your search
@@ -28,15 +28,25 @@ jobs:
|
||||
|
||||
linux:
|
||||
runs-on: ubuntu-24.04
|
||||
# A clean image: the hosted one's zsh and fish setup breaks the shell tests.
|
||||
container: docker.gitea.com/runner-images:ubuntu-24.04
|
||||
env:
|
||||
CARGO_PROFILE_DEV_DEBUG: 0
|
||||
steps:
|
||||
- uses: actions/checkout@v7
|
||||
# The job container comes without rustup.
|
||||
- run: |
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --no-modify-path --default-toolchain none
|
||||
echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
|
||||
- run: rustup toolchain install --no-self-update
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
# The job container runs as root, which ignores the file permissions the tests check.
|
||||
- run: |
|
||||
sudo apt-get update && sudo apt-get install -y --no-install-recommends pkg-config libwayland-dev \
|
||||
apt-get update && apt-get install -y --no-install-recommends pkg-config libwayland-dev \
|
||||
libxkbcommon-dev libxkbcommon-x11-dev libxcb1-dev libx11-xcb-dev libfontconfig-dev \
|
||||
libfreetype-dev zsh fish xvfb
|
||||
- run: cargo test --locked --quiet
|
||||
useradd --create-home ci
|
||||
chmod o+x "$HOME"
|
||||
chown -R ci "$GITHUB_WORKSPACE" "$HOME/.cargo" "$HOME/.rustup"
|
||||
runuser -u ci -- env HOME=/home/ci CARGO_HOME="$HOME/.cargo" RUSTUP_HOME="$HOME/.rustup" PATH="$PATH" cargo test --locked --quiet
|
||||
- run: cargo build --locked
|
||||
Reference in new issue
Block a user