zarf icon indicating copy to clipboard operation
zarf copied to clipboard

zarf-lib: expose the cluster in the packager

Open UncleGedd opened this issue 5 months ago • 0 comments

Is your feature request related to a problem? Please describe.

Problem

In UDS CLI we are creating a record of each bundled Zarf package that has been deployed. This record is implemented as a K8s secret. The issue is that some UDS bundles have Zarf packages that create the K8s cluster, but if a user already has a live cluster in their k8s context, then the secret is created in the wrong cluster.

To mitigate this issue we'd like to ensure that we're using the same cluster that Zarf is using during deploys.

TLDR

We're using Zarf as a library, and want to know which cluster a package/component is using for the deploy. To that end would like to be able to retrieve the k8s client that Zarf is using in its Packager

Describe the solution you'd like

Either make the cluster field in Packager public or provide a getter

UncleGedd avatar Sep 06 '24 18:09 UncleGedd