diff --git a/internal/core/constants.go b/internal/core/constants.go index 967728a..7ad4a75 100644 --- a/internal/core/constants.go +++ b/internal/core/constants.go @@ -19,10 +19,12 @@ const ( DefaultGoVersion = "1.23.0" DefaultPostgresVersion = "16" DefaultLinkerdAwaitVersion = "0.2.7" - DefaultGitHubComRunnerType = "ubuntu-latest" + DefaultGitHubComRunsOn = "ubuntu-latest" ) -var DefaultGitHubEnterpriseRunnerType = [...]string{"self-hosted"} +var DefaultGitHubEnterpriseRunsOn = map[string][]string{ + "groups": {"Default"}, +} const ( CheckoutAction = "actions/checkout@v4" diff --git a/internal/ghworkflow/utils.go b/internal/ghworkflow/utils.go index 46d800f..4d8e10e 100644 --- a/internal/ghworkflow/utils.go +++ b/internal/ghworkflow/utils.go @@ -37,23 +37,23 @@ func pushAndPRTriggers(defaultBranch string, ignorePaths []string) eventTrigger func baseJob(name string, isSelfHostedRunner bool) job { var ( - runnerType any - envs map[string]string + runsOn any + envs map[string]string ) if isSelfHostedRunner { - runnerType = core.DefaultGitHubEnterpriseRunnerType + runsOn = core.DefaultGitHubEnterpriseRunsOn envs = map[string]string{ "NODE_EXTRA_CA_CERTS": "/etc/ssl/certs/ca-certificates.crt", } } else { - runnerType = core.DefaultGitHubComRunnerType + runsOn = core.DefaultGitHubComRunsOn } return job{ Name: name, Env: envs, - RunsOn: runnerType, + RunsOn: runsOn, Steps: []jobStep{{ Name: "Check out code", Uses: core.CheckoutAction,