Self-Hosted GitHub Runners (Windows)
Step-by-step guide for provisioning a Windows 10/11 (x64) machine as a self-hosted GitHub Actions runner for the Ever Gauzy project.
примечание
Runner version: 2.331.0 (update the version and checksum below as needed) Estimated time: ~1–2 hours (Visual Studio Build Tools takes the longest)
Prerequisites
- A fresh or clean Windows 10/11 machine with administrator access
- Internet connectivity
- A GitHub organization runner registration token — see Adding self-hosted runners
подсказка
All commands in this guide must be run in an elevated (Administrator) PowerShell terminal.
Step 1 — Install the GitHub Actions Runner
mkdir C:\actions-runner; cd C:\actions-runner
# Download the runner
Invoke-WebRequest -Uri https://github.com/actions/runner/releases/download/v2.331.0/actions-runner-win-x64-2.331.0.zip -OutFile actions-runner-win-x64-2.331.0.zip
# Verify checksum
if ((Get-FileHash -Path actions-runner-win-x64-2.331.0.zip -Algorithm SHA256).Hash.ToUpper() -ne '473e74b86cd826e073f1c1f2c004d3fb9e6c9665d0d51710a23e5084a601c78a'.ToUpper()) {
throw 'Computed checksum did not match'
}
# Extract
Add-Type -AssemblyName System.IO.Compression.FileSystem
[System.IO.Compression.ZipFile]::ExtractToDirectory("$PWD\actions-runner-win-x64-2.331.0.zip", "$PWD")
Step 2 — Configure the Runner
# Replace YOUR_TOKEN with the registration token from GitHub
./config.cmd --url https://github.com/ever-co --token YOUR_TOKEN
Get a token from GitHub → Organization Settings → Actions → Runners → New self-hosted runner. Tokens are short-lived, so generate one right before running this command.
Step 3 — Enable Long Path Support
Windows has a 260-character path limit by default, which breaks many Node.js projects.
reg add "HKLM\SYSTEM\CurrentControlSet\Control\FileSystem" /v LongPathsEnabled /t REG_DWORD /d 1 /f
warning
A reboot is required for this change to take full effect.