Unverified Commit 01688850 authored by Dr. Stefan Schimanski's avatar Dr. Stefan Schimanski Committed by GitHub
Browse files

fix(operator/deploy/tilt): build helm dependencies automatically (#8155)


Signed-off-by: default avatarDr. Stefan Schimanski <sschimanski@nvidia.com>
parent 303520f8
...@@ -154,6 +154,27 @@ local_resource( ...@@ -154,6 +154,27 @@ local_resource(
labels=['operator'], labels=['operator'],
) )
# ---------------------------------------------------------------------------
# Helm dependencies — fetch remote subcharts and package the local operator
# subchart (file://components/operator).
# ---------------------------------------------------------------------------
# Ensure Helm repos for non-OCI dependencies are registered.
local(helm_cmd + ' repo add --force-update nats https://nats-io.github.io/k8s/helm/charts/', quiet=True)
local(helm_cmd + ' repo add --force-update bitnami https://charts.bitnami.com/bitnami', quiet=True)
local(helm_cmd + ' repo update', quiet=True)
# Initial build at load time so render_helm() can succeed.
local(helm_cmd + ' dependency build ' + HELM_CHART, quiet=True)
# Re-run when the local operator subchart changes.
local_resource(
'helm-dep-build',
helm_cmd + ' dependency build ' + HELM_CHART,
deps=[os.path.join(HELM_CHART, 'components', 'operator'), os.path.join(HELM_CHART, 'Chart.yaml')],
labels=['operator'],
)
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
# Helm template → k8s_yaml # Helm template → k8s_yaml
# #
...@@ -272,7 +293,7 @@ k8s_resource( ...@@ -272,7 +293,7 @@ k8s_resource(
new_name='operator', new_name='operator',
labels=['operator'], labels=['operator'],
port_forwards=['8081:8081'], # health endpoint port_forwards=['8081:8081'], # health endpoint
resource_deps=['crds', 'manager-build'], resource_deps=['crds', 'manager-build', 'helm-dep-build'],
) )
# Group subchart workloads in the Tilt UI # Group subchart workloads in the Tilt UI
......
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