Skip to content

Commit

Permalink
Update Linux and Windows build workflows to use architecture-specific…
Browse files Browse the repository at this point in the history
… runners and add dynamic port allocation in profileserver.py
  • Loading branch information
mauro-balades committed Jan 6, 2025
1 parent 6db0883 commit 4124a3c
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/linux-release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
build-linux:
permissions:
contents: write
runs-on: ${{ inputs.release-branch == 'release' && 'warp-ubuntu-latest-x64-8x' || 'ubuntu-latest' }}
runs-on: ${{ matrix.arch == 'x86_64' && 'warp-ubuntu-latest-x64-8x' || 'ubuntu-latest' }}
strategy:
fail-fast: false
matrix:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/windows-release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ on:
jobs:
windows-build:
name: Build Windows - ${{ matrix.arch }}
runs-on: ${{ (inputs.release-branch == 'release' && !(inputs.generate-gpo && matrix.arch == 'aarch64')) && 'warp-ubuntu-latest-x64-8x' || 'ubuntu-latest' }}
runs-on: ${{ (inputs.release-branch == 'release' && !(inputs.generate-gpo && matrix.arch == 'aarch64')) && 'warp-ubuntu-latest-x64-6x' || 'ubuntu-latest' }}

strategy:
fail-fast: false
Expand Down
19 changes: 19 additions & 0 deletions src/build/pgo/profileserver-py.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
diff --git a/build/pgo/profileserver.py b/build/pgo/profileserver.py
index 31556cc9ae1a44a04e300083f7be4dc908cc3794..23ef1d8f5b30068ffdddc3c9cb6cd45e64d93071 100755
--- a/build/pgo/profileserver.py
+++ b/build/pgo/profileserver.py
@@ -18,7 +18,13 @@ from mozprofile import FirefoxProfile, Preferences
from mozprofile.permissions import ServerLocations
from mozrunner import CLI, FirefoxRunner

-PORT = 8888
+import socket
+def find_free_port():
+ with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s:
+ s.bind(('', 0))
+ return s.getsockname()[1]
+
+PORT = find_free_port()

PATH_MAPPINGS = {
"/webkit/PerformanceTests": "third_party/webkit/PerformanceTests",

0 comments on commit 4124a3c

Please sign in to comment.