Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CI] filter static versus ephemeral workers #22607

Merged
merged 2 commits into from
Nov 17, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,14 @@ def notifyBuildReason() {
*/
def withNode(def label, Closure body) {
def uuid = UUID.randomUUID().toString()
v1v marked this conversation as resolved.
Show resolved Hide resolved
def labels = label?.trim() ? "${label} && extra/${uuid}" : "extra/${uuid}"
def labels
// There are immutable workers and static ones, so the static ones are only metal, macosx and arm
if (label.contains('arm') || label.contains('macosx') || label.contains('metal')) {
labels = label
} else {
// Otherwise use the dynamic UUID for the gobld
labels = label?.trim() ? "${label} && extra/${uuid}" : "extra/${uuid}"
}
node("${labels}") {
body()
}
Expand Down