Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/actionlint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ self-hosted-runner:
labels:
- 8core_ubuntu_latest_runner
- 16core_windows_latest_runner
- windows_arm64_2025_large
- windows_x64_2025_large

paths:
.github/workflows/release.yml:
Expand Down
20 changes: 10 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -222,14 +222,14 @@ jobs:
PIXI_TEST_R2_SECRET_ACCESS_KEY: ${{ secrets.PIXI_TEST_R2_SECRET_ACCESS_KEY }}

cargo-test-windows:
name: "cargo test | windows"
name: "cargo test | windows x64"
timeout-minutes: 15
needs: determine_changes
if: ${{ needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main' }}
runs-on: 16core_windows_latest_runner
runs-on: windows_x64_2025_large
steps:
- uses: actions/checkout@v4
- name: Create Dev Drive using ReFS
- name: Create Dev Drive
run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1
- uses: prefix-dev/setup-pixi@v0.8.3
with:
Expand Down Expand Up @@ -323,11 +323,11 @@ jobs:
build-binary-windows-x86_64:
needs: determine_changes
if: ${{ needs.determine_changes.outputs.code == 'true' || github.ref == 'refs/heads/main' }}
runs-on: 16core_windows_latest_runner
runs-on: windows_x64_2025_large
name: "build binary | windows x86_64"
steps:
- uses: actions/checkout@v4
- name: Create Dev Drive using ReFS
- name: Create Dev Drive
run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1
- name: Copy Git Repo to Dev Drive
run: |
Expand All @@ -352,11 +352,11 @@ jobs:
build-binary-windows-aarch64:
needs: determine_changes
if: ${{ needs.determine_changes.outputs.code == 'true' && github.ref == 'refs/heads/main' }} # Only run on the main branch
runs-on: 16core_windows_latest_runner
runs-on: windows_arm64_2025_large
name: "build binary | windows aarch64"
steps:
- uses: actions/checkout@v4
- name: Create Dev Drive using ReFS
- name: Create Dev Drive
run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1
- name: Copy Git Repo to Dev Drive
run: |
Expand Down Expand Up @@ -394,7 +394,7 @@ jobs:
TARGET_RELEASE: "target/pixi/release"
steps:
- uses: actions/checkout@v4
- name: Create Dev Drive using ReFS
- name: Create Dev Drive
run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1
- name: Copy Git Repo to Dev Drive
run: |
Expand Down Expand Up @@ -471,7 +471,7 @@ jobs:
TARGET_RELEASE: "target/pixi/release"
steps:
- uses: actions/checkout@v4
- name: Create Dev Drive using ReFS
- name: Create Dev Drive
run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1
- name: Copy Git Repo to Dev Drive
run: |
Expand Down Expand Up @@ -575,7 +575,7 @@ jobs:
TARGET_RELEASE: "target/pixi/release"
steps:
- uses: actions/checkout@v4
- name: Create Dev Drive using ReFS
- name: Create Dev Drive
run: ${{ github.workspace }}/.github/workflows/setup-dev-drive.ps1
- name: Copy Git Repo to Dev Drive
run: |
Expand Down
59 changes: 47 additions & 12 deletions .github/workflows/setup-dev-drive.ps1
Original file line number Diff line number Diff line change
@@ -1,20 +1,55 @@
# This creates a 20GB dev drive, and exports all required environment
# variables so that rustup, pixi and others all use the dev drive as much
# as possible.
$Volume = New-VHD -Path C:/pixi_dev_drive.vhdx -SizeBytes 20GB |
Mount-VHD -Passthru |
Initialize-Disk -Passthru |
New-Partition -AssignDriveLetter -UseMaximumSize |
Format-Volume -FileSystem ReFS -Confirm:$false -Force

Write-Output $Volume

$Drive = "$($Volume.DriveLetter):"
# Configures a drive for testing in CI.
# Credits to astral-sh/uv: https://github.com/astral-sh/uv/blob/d2b9ffdc9e3f336e46b0af18a8554de560bfbefc/.github/workflows/setup-dev-drive.ps1

# When not using a GitHub Actions "larger runner", the `D:` drive is present and
# has similar or better performance characteristics than a ReFS dev drive.
# Sometimes using a larger runner is still more performant (e.g., when running
# the test suite) and we need to create a dev drive. This script automatically
# configures the appropriate drive.
if (Test-Path "D:\") {
Write-Output "Using existing drive at D:"
$Drive = "D:"
} else {
# The size (20 GB) is chosen empirically to be large enough for our
# workflows; larger drives can take longer to set up.
$Volume = New-VHD -Path C:/pixi_dev_drive.vhdx -SizeBytes 20GB |
Mount-VHD -Passthru |
Initialize-Disk -Passthru |
New-Partition -AssignDriveLetter -UseMaximumSize |
Format-Volume -DevDrive -Confirm:$false -Force

$Drive = "$($Volume.DriveLetter):"

# Set the drive as trusted
# See https://learn.microsoft.com/en-us/windows/dev-drive/#how-do-i-designate-a-dev-drive-as-trusted
fsutil devdrv trust $Drive

# Disable antivirus filtering on dev drives
# See https://learn.microsoft.com/en-us/windows/dev-drive/#how-do-i-configure-additional-filters-on-dev-drive
fsutil devdrv enable /disallowAv

# Remount so the changes take effect
Dismount-VHD -Path C:/pixi_dev_drive.vhdx
Mount-VHD -Path C:/pixi_dev_drive.vhdx

# Show some debug information
Write-Output $Volume
fsutil devdrv query $Drive

Write-Output "Using Dev Drive at $Volume"
}

$Tmp = "$($Drive)/pixi-tmp"

# Create the directory ahead of time in an attempt to avoid race-conditions
New-Item $Tmp -ItemType Directory

# Move Cargo to the dev drive
New-Item -Path "$($Drive)/.cargo/bin" -ItemType Directory -Force
if (Test-Path "C:/Users/runneradmin/.cargo") {
Copy-Item -Path "C:/Users/runneradmin/.cargo/*" -Destination "$($Drive)/.cargo/" -Recurse -Force
}

Write-Output `
"DEV_DRIVE=$($Drive)" `
"TMP=$($Tmp)" `
Expand Down
Loading