Skip to content

Commit 239bafa

Browse files
authored
Merge pull request #6244 from detiber/tiltClusterName
🐛 [Tilt] Support using kind cluster from tilt settings automatically
2 parents a367af9 + 5de04b2 commit 239bafa

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

Tiltfile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ version_settings(True, ">=0.22.2")
88
settings = {
99
"deploy_cert_manager": True,
1010
"enable_providers": ["docker"],
11+
"kind_cluster_name": os.getenv("CAPI_KIND_CLUSTER_NAME", "capi-test"),
1112
"debug": {},
1213
}
1314

@@ -18,6 +19,8 @@ settings.update(read_yaml(
1819
default = {},
1920
))
2021

22+
os.putenv("CAPI_KIND_CLUSTER_NAME", settings.get("kind_cluster_name"))
23+
2124
allow_k8s_contexts(settings.get("allowed_contexts"))
2225

2326
os_name = str(local("go env GOOS")).rstrip("\n")

docs/book/src/developer/tilt.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,8 @@ If you prefer JSON, you can create a `tilt-settings.json` file instead. YAML wil
6363
**default_registry** (String, default=""): The image registry to use if you need to push images. See the [Tilt
6464
documentation](https://docs.tilt.dev/api.html#api.default_registry) for more details.
6565

66+
**kind_cluster_name** (String, default="capi-test"): The name of the kind cluster to use when preloading images.
67+
6668
**provider_repos** (Array[]String, default=[]): A list of paths to all the providers you want to use. Each provider must have a
6769
`tilt-provider.yaml` or `tilt-provider.json` file describing how to build the provider.
6870

0 commit comments

Comments
 (0)