fix(ci): avoid slow Azure archive for the native cross compiler (#1016)

* fix(ci): avoid slow Azure archive for the native cross compiler

* fix(ci): use HTTPS for Ubuntu archive transfers
This commit is contained in:
Ysopwnable
2026-10-08 03:08:53 +08:00
committed by GitHub
parent 93731e17dd
commit 51956c1a49
+10 -1
View File
@@ -231,7 +231,16 @@ jobs:
with:
node-version-file: .nvmrc
- name: Prepare cross compiler
run: sudo apt-get update && sudo apt-get install --no-install-recommends -y g++-mingw-w64-x86-64
run: |
# Slow Azure archive transfers can exhaust the job before compilation.
# Keep the same signed packages and avoid slow HTTP mirror fallback.
for source in /etc/apt/apt-mirrors.txt /etc/apt/sources.list /etc/apt/sources.list.d/ubuntu.sources; do
if [ -f "$source" ]; then
sudo sed -i 's|azure.archive.ubuntu.com|archive.ubuntu.com|g; s|http://archive.ubuntu.com|https://archive.ubuntu.com|g' "$source"
fi
done
sudo apt-get update
sudo apt-get install --no-install-recommends -y g++-mingw-w64-x86-64
- run: npm run build:windows-native
- run: npm run verify:windows-native:artifact
- uses: actions/upload-artifact@v4