ci: explicitly specify architecture in runner labels

This commit is contained in:
Ivan Dyachkov 2023-10-17 18:57:46 +02:00
parent 4dd60da9ee
commit fb6b02c1ea
6 changed files with 10 additions and 10 deletions

View File

@ -16,7 +16,7 @@ env:
jobs: jobs:
sanity-checks: sanity-checks:
runs-on: ${{ fromJSON(github.repository_owner == 'emqx' && '["self-hosted","ephemeral"]' || '["ubuntu-22.04"]') }} runs-on: ${{ fromJSON(github.repository_owner == 'emqx' && '["self-hosted","ephemeral","linux","x64"]' || '["ubuntu-22.04"]') }}
container: "ghcr.io/emqx/emqx-builder/5.1-4:1.14.5-25.3.2-2-ubuntu22.04" container: "ghcr.io/emqx/emqx-builder/5.1-4:1.14.5-25.3.2-2-ubuntu22.04"
outputs: outputs:
ct-matrix: ${{ steps.matrix.outputs.ct-matrix }} ct-matrix: ${{ steps.matrix.outputs.ct-matrix }}
@ -24,7 +24,7 @@ jobs:
ct-docker: ${{ steps.matrix.outputs.ct-docker }} ct-docker: ${{ steps.matrix.outputs.ct-docker }}
version-emqx: ${{ steps.matrix.outputs.version-emqx }} version-emqx: ${{ steps.matrix.outputs.version-emqx }}
version-emqx-enterprise: ${{ steps.matrix.outputs.version-emqx-enterprise }} version-emqx-enterprise: ${{ steps.matrix.outputs.version-emqx-enterprise }}
runner_labels: ${{ github.repository_owner == 'emqx' && '["self-hosted", "ephemeral"]' || '["ubuntu-22.04"]' }} runner_labels: ${{ github.repository_owner == 'emqx' && '["self-hosted","ephemeral","linux","x64"]' || '["ubuntu-22.04"]' }}
builder: "ghcr.io/emqx/emqx-builder/5.1-4:1.14.5-25.3.2-2-ubuntu22.04" builder: "ghcr.io/emqx/emqx-builder/5.1-4:1.14.5-25.3.2-2-ubuntu22.04"
builder_vsn: "5.1-4" builder_vsn: "5.1-4"
otp_vsn: "25.3.2-2" otp_vsn: "25.3.2-2"
@ -57,8 +57,8 @@ jobs:
env: env:
ACTIONLINT_VSN: 1.6.25 ACTIONLINT_VSN: 1.6.25
run: | run: |
wget https://github.com/rhysd/actionlint/releases/download/v${ACTIONLINT_VSN}/actionlint_${ACTIONLINT_VSN}_linux_amd64.tar.gz wget -q https://github.com/rhysd/actionlint/releases/download/v${ACTIONLINT_VSN}/actionlint_${ACTIONLINT_VSN}_linux_$(dpkg --print-architecture).tar.gz -O actionlint.tar.gz
tar zxf actionlint_${ACTIONLINT_VSN}_linux_amd64.tar.gz actionlint tar zxf actionlint.tar.gz actionlint
# TODO: enable shellcheck when all the current issues are fixed # TODO: enable shellcheck when all the current issues are fixed
./actionlint -color \ ./actionlint -color \
-shellcheck= \ -shellcheck= \

View File

@ -19,7 +19,7 @@ env:
jobs: jobs:
prepare: prepare:
runs-on: ${{ fromJSON(github.repository_owner == 'emqx' && '["self-hosted", "ephemeral"]' || '["ubuntu-22.04"]') }} runs-on: ${{ fromJSON(github.repository_owner == 'emqx' && '["self-hosted","ephemeral","linux","x64"]' || '["ubuntu-22.04"]') }}
container: 'ghcr.io/emqx/emqx-builder/5.1-4:1.14.5-25.3.2-2-ubuntu22.04' container: 'ghcr.io/emqx/emqx-builder/5.1-4:1.14.5-25.3.2-2-ubuntu22.04'
outputs: outputs:
profile: ${{ steps.parse-git-ref.outputs.profile }} profile: ${{ steps.parse-git-ref.outputs.profile }}
@ -29,7 +29,7 @@ jobs:
ct-matrix: ${{ steps.matrix.outputs.ct-matrix }} ct-matrix: ${{ steps.matrix.outputs.ct-matrix }}
ct-host: ${{ steps.matrix.outputs.ct-host }} ct-host: ${{ steps.matrix.outputs.ct-host }}
ct-docker: ${{ steps.matrix.outputs.ct-docker }} ct-docker: ${{ steps.matrix.outputs.ct-docker }}
runner_labels: ${{ github.repository_owner == 'emqx' && '["self-hosted", "ephemeral"]' || '["ubuntu-22.04"]' }} runner_labels: ${{ github.repository_owner == 'emqx' && '["self-hosted","ephemeral","linux","x64"]' || '["ubuntu-22.04"]' }}
builder: 'ghcr.io/emqx/emqx-builder/5.1-4:1.14.5-25.3.2-2-ubuntu22.04' builder: 'ghcr.io/emqx/emqx-builder/5.1-4:1.14.5-25.3.2-2-ubuntu22.04'
builder_vsn: '5.1-4' builder_vsn: '5.1-4'
otp_vsn: '25.3.2-2' otp_vsn: '25.3.2-2'

View File

@ -73,7 +73,7 @@ on:
runner_labels: runner_labels:
required: false required: false
type: string type: string
default: '["self-hosted","ephemeral", "linux"]' default: '["self-hosted","ephemeral","linux","x64"]'
jobs: jobs:
docker: docker:

View File

@ -151,7 +151,7 @@ jobs:
path: _packages/${{ matrix.profile }}/ path: _packages/${{ matrix.profile }}/
linux: linux:
runs-on: ['self-hosted', 'linux', "${{ matrix.arch }}"] runs-on: ['self-hosted', 'ephemeral', 'linux', "${{ matrix.arch }}"]
# always run in builder container because the host might have the wrong OTP version etc. # always run in builder container because the host might have the wrong OTP version etc.
# otherwise buildx.sh does not run docker if arch and os matches the target arch and os. # otherwise buildx.sh does not run docker if arch and os matches the target arch and os.
container: container:

View File

@ -12,7 +12,7 @@ on:
jobs: jobs:
linux: linux:
if: github.repository_owner == 'emqx' if: github.repository_owner == 'emqx'
runs-on: ['self-hosted', 'linux', "${{ matrix.arch }}", 'ephemeral'] runs-on: ['self-hosted', 'ephemeral', 'linux', "${{ matrix.arch }}"]
container: container:
image: "ghcr.io/emqx/emqx-builder/${{ matrix.builder }}:${{ matrix.elixir }}-${{ matrix.otp }}-${{ matrix.os }}" image: "ghcr.io/emqx/emqx-builder/${{ matrix.builder }}:${{ matrix.elixir }}-${{ matrix.otp }}-${{ matrix.os }}"

View File

@ -30,7 +30,7 @@ on:
runner_labels: runner_labels:
required: false required: false
type: string type: string
default: '["self-hosted","ephemeral"]' default: '["self-hosted","ephemeral", "linux", "x64"]'
builder: builder:
required: false required: false
type: string type: string