Add simple Builder for the hello_world recipe This is from LUCI's onboarding docs Change-Id: Ifb373f87be6d7d378a8c9785af5d9d24915282d5
diff --git a/generated/cr-buildbucket.cfg b/generated/cr-buildbucket.cfg index 5c8967b..0e23f27 100644 --- a/generated/cr-buildbucket.cfg +++ b/generated/cr-buildbucket.cfg
@@ -6,6 +6,25 @@ buckets { name: "ci" + swarming { + builders { + name: "Example Builder" + swarming_host: "chromium-swarm.appspot.com.appspot.com" + exe { + cipd_package: "infra/recipe_bundles/gerrit.googlesource.com/luci-config" + cipd_version: "refs/heads/main" + cmd: "luciexe" + } + properties: + '{' + ' "recipe": "hello_world"' + '}' + experiments { + key: "luci.recipes.use_python3" + value: 100 + } + } + } } buckets { name: "prod"
diff --git a/generated/luci-scheduler.cfg b/generated/luci-scheduler.cfg new file mode 100644 index 0000000..9b580dc --- /dev/null +++ b/generated/luci-scheduler.cfg
@@ -0,0 +1,16 @@ +# Auto-generated by lucicfg. +# Do not modify manually. +# +# For the schema of this file, see ProjectConfig message: +# https://luci-config.appspot.com/schemas/projects:luci-scheduler.cfg + +job { + id: "Example Builder" + realm: "ci" + schedule: "with 1m interval" + buildbucket { + server: "cr-buildbucket.appspot.com" + bucket: "ci" + builder: "Example Builder" + } +}
diff --git a/main.star b/main.star index 0a51661..d79510b 100755 --- a/main.star +++ b/main.star
@@ -66,3 +66,32 @@ # The prod bucket will include builders which work on post-commit code and # generate executable artifacts used by other users or machines. luci.bucket(name = "prod") + +# Builders + +# This is the cipd package where the recipe bundler will put the built recipes. +# This line makes it the default value for all `luci.recipe` invocations in +# this configuration. +luci.recipe.defaults.cipd_package.set("infra/recipe_bundles/gerrit.googlesource.com/luci-config") + +# This sets the default CIPD ref to use in builds to get the right version of +# recipes for the build. +# +# The recipe bundler sets CIPD refs equal in name to the git refs that it +# processed the recipe code from. +# +# Note: This will cause all recipe commits to automatically deploy as soon +# as the recipe bundler compiles them from your refs/heads/main branch. +cipd_version = "refs/heads/main" + +luci.builder( + name = "Example Builder", + bucket = "ci", + + executable = luci.recipe( + # The name of the recipe we just added. + name = "hello_world", + ), + + schedule = "with 1m interval", +)