This repository was archived by the owner on Nov 24, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +12
-10
lines changed Expand file tree Collapse file tree 1 file changed +12
-10
lines changed Original file line number Diff line number Diff line change 67
67
$assured_labels = ' '
68
68
}
69
69
70
- if $repo_name {
71
- $token_url = " ${github_api} /repos/${org_name} /${repo_name} /actions/runners/registration-token"
72
- $url = " ${github_domain} /${org_name} /${repo_name} "
73
- } elsif $org_name {
74
- $token_url = $github_api ? {
75
- ' https://api.github.com' => " ${github_api} /repos/${org_name} /actions/runners/registration-token" ,
76
- default => " ${github_api} /orgs/${org_name} /actions/runners/registration-token" ,
77
- }
78
- $url = " ${github_domain} /${org_name} "
70
+
71
+ if $org_name {
72
+ if $repo_name {
73
+ $token_url = " ${github_api} /repos/${org_name} /${repo_name} /actions/runners/registration-token"
74
+ $url = " ${github_domain} /${org_name} /${repo_name} "
75
+ } else {
76
+ $token_url = $github_api ? {
77
+ ' https://api.github.com' => " ${github_api} /repos/${org_name} /actions/runners/registration-token" ,
78
+ default => " ${github_api} /orgs/${org_name} /actions/runners/registration-token" ,
79
+ }
80
+ $url = " ${github_domain} /${org_name} "
79
81
} elsif $enterprise_name {
80
82
$token_url = " ${github_api} /enterprises/${enterprise_name} /actions/runners/registration-token"
81
83
$url = " ${github_domain} /enterprises/${enterprise_name} "
82
84
} else {
83
- fail(" At least one of 'repo_name', ' org_name', 'enterprise_name' is required to create runner instances. " )
85
+ fail(" Either ' org_name' or 'enterprise_name' is required to create runner instances" )
84
86
}
85
87
86
88
$archive_name = " ${github_actions_runner::package_name} -${github_actions_runner::package_ensure} .tar.gz"
You can’t perform that action at this time.
0 commit comments