Commit 42016da9 authored by Ben Pastene's avatar Ben Pastene Committed by Commit Bot

infra: Define all xcode cache paths in lib/builders.star

Moves all the values of xcode into a shareable location.

Will upgrade bots to the newer path in a follow-up, in case it
gets reverted.

Bug: 1048301
Change-Id: I18e2aebb67fd2bff879b24159d4f7210801d9f84
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2036495
Commit-Queue: Ben Pastene <bpastene@chromium.org>
Commit-Queue: John Budorick <jbudorick@chromium.org>
Auto-Submit: Ben Pastene <bpastene@chromium.org>
Reviewed-by: default avatarJohn Budorick <jbudorick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#737955}
parent 4286d3b8
load('//lib/builders.star', 'cpu', 'goma', 'os')
load('//lib/builders.star', 'cpu', 'goma', 'os', 'xcode_cache')
load('//lib/ci.star', 'ci')
# Defaults that apply to all branch versions of the bucket
......@@ -27,12 +27,6 @@ ci.defaults.bucket.set('ci')
ci.defaults.triggered_by.set(['master-gitiles-trigger'])
XCODE_IOS_11_CACHE = swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
)
# Builders are sorted first lexicographically by the function used to define
# them, then lexicographically by their name
......@@ -1077,7 +1071,7 @@ ci.fyi_coverage_builder(
ci.fyi_coverage_builder(
name = 'ios-simulator-code-coverage',
caches = [XCODE_IOS_11_CACHE],
caches = [xcode_cache.x11a1027],
cores = None,
goma_backend = None, # TODO(crbug.com/950413): Use goma.backend.RBE_PROD
os = os.MAC_ANY,
......
load('//lib/builders.star', 'builder', 'cpu', 'defaults', 'goma', 'os')
load('//lib/builders.star', 'builder', 'cpu', 'defaults', 'goma', 'os', 'xcode_cache')
luci.bucket(
name = 'goma',
......@@ -117,12 +117,7 @@ fyi_goma_canary_builder(
fyi_goma_canary_builder(
name = 'ios-device-goma-canary-clobber',
caches = [
swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
),
],
caches = [xcode_cache.x11a1027],
cores = None,
executable = 'recipe:ios/unified_builder_tester',
os = os.MAC_ANY,
......@@ -196,12 +191,7 @@ fyi_goma_rbe_canary_builder(
fyi_goma_rbe_canary_builder(
name = 'ios-device-goma-rbe-canary-clobber',
caches = [
swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
),
],
caches = [xcode_cache.x11a1027],
cores = None,
executable = 'recipe:ios/unified_builder_tester',
os = os.MAC_ANY,
......@@ -295,12 +285,7 @@ fyi_goma_latest_client_builder(
fyi_goma_latest_client_builder(
name = 'ios-device-goma-latest-clobber',
caches = [
swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
),
],
caches = [xcode_cache.x11a1027],
cores = None,
executable = 'recipe:ios/unified_builder_tester',
os = os.MAC_ANY,
......@@ -388,12 +373,7 @@ fyi_goma_rbe_latest_client_builder(
fyi_goma_rbe_latest_client_builder(
name = 'ios-device-goma-rbe-latest-clobber',
caches = [
swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
),
],
caches = [xcode_cache.x11a1027],
cores = None,
executable = 'recipe:ios/unified_builder_tester',
os = os.MAC_ANY,
......
load('//lib/builders.star', 'builder', 'cpu', 'defaults', 'goma', 'os')
load('//lib/builders.star', 'builder', 'cpu', 'defaults', 'goma', 'os', 'xcode_cache')
luci.bucket(
name = 'webrtc.fyi',
......@@ -88,12 +88,7 @@ builder(
builder(
name = 'WebRTC Chromium FYI Mac Builder',
cores = 8,
caches = [
swarming.cache(
name = 'xcode_ios_10e1001',
path = 'xcode_ios_10e1001.app',
),
],
caches = [xcode_cache.x10e1001],
goma_backend = goma.backend.RBE_PROD,
os = os.MAC_ANY,
properties = {
......@@ -104,12 +99,7 @@ builder(
builder(
name = 'WebRTC Chromium FYI Mac Builder (dbg)',
cores = 8,
caches = [
swarming.cache(
name = 'xcode_ios_10e1001',
path = 'xcode_ios_10e1001.app',
),
],
caches = [xcode_cache.x10e1001],
goma_backend = goma.backend.RBE_PROD,
os = os.MAC_ANY,
properties = {
......@@ -119,12 +109,7 @@ builder(
builder(
name = 'WebRTC Chromium FYI Mac Tester',
caches = [
swarming.cache(
name = 'xcode_ios_10e1001',
path = 'xcode_ios_10e1001.app',
),
],
caches = [xcode_cache.x10e1001],
os = os.MAC_ANY,
properties = {
'xcode_build_version': '10e1001',
......@@ -164,24 +149,14 @@ builder(
builder(
name = 'WebRTC Chromium FYI ios-device',
caches = [
swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
),
],
caches = [xcode_cache.x11a1027],
executable = 'recipe:webrtc/chromium_ios',
os = os.MAC_ANY,
)
builder(
name = 'WebRTC Chromium FYI ios-simulator',
caches = [
swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
),
],
caches = [xcode_cache.x11a1027],
executable = 'recipe:webrtc/chromium_ios',
os = os.MAC_ANY,
)
......@@ -120,6 +120,18 @@ goma = struct(
)
def xcode_enum(cache_name, cache_path):
return swarming.cache(name=cache_name, path=cache_path)
# Keep this in-sync with the versions of bots in //ios/build/bots/.
xcode_cache = struct(
x10e1001 = xcode_enum('xcode_ios_10e1001', 'xcode_ios_10e1001.app'),
x11a1027 = xcode_enum('xcode_ios_11a1027', 'xcode_ios_11a1027.app'),
x11c29 = xcode_enum('xcode_ios_11c29', 'xcode_ios_11c29.app'),
)
################################################################################
# Implementation details #
################################################################################
......@@ -438,4 +450,5 @@ builders = struct(
defaults = defaults,
goma = goma,
os = os,
xcode_cache = xcode_cache,
)
......@@ -90,16 +90,10 @@ def clang_builder(*, name, cores=32, properties=None, **kwargs):
)
XCODE_IOS_11_CACHE = swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
)
def clang_ios_builder(*, name, **kwargs):
return clang_builder(
name = name,
caches = [XCODE_IOS_11_CACHE],
caches = [builders.xcode_cache.x11a1027],
cores = None,
executable = 'recipe:ios/unified_builder_tester',
os = builders.os.MAC_10_14,
......@@ -208,7 +202,7 @@ def fyi_ios_builder(
**kwargs):
return fyi_builder(
name = name,
caches = [XCODE_IOS_11_CACHE],
caches = [builders.xcode_cache.x11a1027],
cores = None,
executable = executable,
goma_backend = None,
......@@ -362,7 +356,7 @@ def mac_builder(
def mac_ios_builder(*, name, **kwargs):
return mac_builder(
name = name,
caches = [XCODE_IOS_11_CACHE],
caches = [builders.xcode_cache.x11a1027],
executable = 'recipe:ios/unified_builder_tester',
goma_backend = None,
os = builders.os.MAC_ANY,
......
......@@ -180,12 +180,7 @@ def chromium_mac_builder(
def chromium_mac_ios_builder(*, name, executable='recipe:ios/try', **kwargs):
return try_builder(
name = name,
caches = [
swarming.cache(
name = 'xcode_ios_11a1027',
path = 'xcode_ios_11a1027.app',
),
],
caches = [builders.xcode_cache.x11a1027],
cores = None,
executable = executable,
mastername = 'tryserver.chromium.mac',
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment