Skip to content

Commit

Permalink
ci: allow custom actions runner to be defined (#3989)
Browse files Browse the repository at this point in the history
  • Loading branch information
DavideIadeluca committed May 16, 2024
1 parent a52959c commit 8415d22
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/REUSABLE_backend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,12 @@ on:
required: false
default: error_reporting=E_ALL

runner_type:
description: The type of runner to use for the jobs. This should be one of the types supported by the `runs-on` keyword.
type: string
required: false
default: 'ubuntu-latest'

secrets:
composer_auth:
description: The Composer auth tokens to use for private packages.
Expand All @@ -57,7 +63,7 @@ env:

jobs:
test:
runs-on: ubuntu-latest
runs-on: ${{ inputs.runner_type }}

strategy:
matrix:
Expand Down Expand Up @@ -166,7 +172,7 @@ jobs:
COMPOSER_PROCESS_TIMEOUT: 600

phpstan:
runs-on: ubuntu-latest
runs-on: ${{ inputs.runner_type }}

strategy:
matrix:
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/REUSABLE_frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,12 @@ on:
type: string
required: false

runner_type:
description: The type of runner to use for the jobs. This should be one of the types supported by the `runs-on` keyword.
type: string
required: false
default: 'ubuntu-latest'

secrets:
bundlewatch_github_token:
description: The GitHub token to use for Bundlewatch.
Expand All @@ -103,7 +109,7 @@ env:
jobs:
build:
name: Checks & Build
runs-on: ubuntu-latest
runs-on: ${{ inputs.runner_type }}

if: >-
((github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository) || github.event_name != 'pull_request')
Expand Down

0 comments on commit 8415d22

Please sign in to comment.