@@ -18,7 +18,7 @@ concurrency:
1818
1919jobs :
2020 format :
21- runs-on : ubuntu-x64-large
21+ runs-on : ${{ github.repository_owner == 'grafana' && ' ubuntu-x64-large' || 'ubuntu-latest' }}
2222 steps :
2323 - name : Checkout code
2424 uses : actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4
3131 - name : Format
3232 run : make fmt check/unstaged-changes
3333 check-generated :
34- runs-on : ubuntu-x64-large
34+ runs-on : ${{ github.repository_owner == 'grafana' && ' ubuntu-x64-large' || 'ubuntu-latest' }}
3535 steps :
3636 - name : Checkout code
3737 uses : actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4
4848 fail-fast : false
4949 matrix :
5050 arch : [amd64, arm64]
51- runs-on : ubuntu-${{ matrix.arch }}-large
51+ # Compute runner OS dynamically based on arch and repo ownership
52+ runs-on : >-
53+ ${{
54+ github.repository_owner == 'grafana'
55+ && format('ubuntu-{0}-large', matrix.arch)
56+ || (matrix.arch == 'arm64' && 'ubuntu-24.04-arm' || 'ubuntu-24.04')
57+ }}
5258 steps :
5359 - name : Checkout code
5460 uses : actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4
6369 - name : Test
6470 run : make go/test
6571 lint :
66- runs-on : ubuntu-x64-large
72+ runs-on : ${{ github.repository_owner == 'grafana' && ' ubuntu-x64-large' || 'ubuntu-latest' }}
6773 steps :
6874 - name : Checkout code
6975 uses : actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4
7985 run : make helm/check check/unstaged-changes
8086
8187 test-docs :
82- runs-on : ubuntu-x64-small
88+ runs-on : ${{ github.repository_owner == 'grafana' && ' ubuntu-x64-small' || 'ubuntu-latest' }}
8389 steps :
8490 - name : " Check out code"
8591 uses : " actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955" # v4
9096
9197 build-image :
9298 if : github.event_name != 'push'
93- runs-on : ubuntu-x64
99+ runs-on : ${{ github.repository_owner == 'grafana' && ' ubuntu-x64' || 'ubuntu-latest' }}
94100 steps :
95101 - name : Checkout Repo
96102 uses : actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4
@@ -116,7 +122,7 @@ jobs:
116122 permissions :
117123 contents : read
118124 id-token : write
119- runs-on : ubuntu-x64-large
125+ runs-on : ${{ github.repository_owner == 'grafana' && ' ubuntu-x64-large' || 'ubuntu-latest' }}
120126 outputs :
121127 image : ${{ steps.push-metadata.outputs.image }}
122128 image-digest : ${{ steps.push-metadata.outputs.image-digest }}
@@ -163,7 +169,7 @@ jobs:
163169 contents : read
164170 id-token : write
165171 if : github.event_name == 'push' && github.repository == 'grafana/pyroscope' && github.ref == 'refs/heads/main'
166- runs-on : ubuntu-x64-small
172+ runs-on : ${{ github.repository_owner == 'grafana' && ' ubuntu-x64-small' || 'ubuntu-latest' }}
167173 needs : [build-push]
168174 steps :
169175 - id : " submit-argowfs-deployment"
0 commit comments