diff --git a/packaging/flavorgen/flavors/kubevip/topology.go b/packaging/flavorgen/flavors/kubevip/topology.go index 23667e8e27..d80abc9b44 100644 --- a/packaging/flavorgen/flavors/kubevip/topology.go +++ b/packaging/flavorgen/flavors/kubevip/topology.go @@ -75,7 +75,7 @@ func TopologyPatch() clusterv1.ClusterClassPatch { if f.Path == "/etc/kubernetes/manifests/kube-vip.yaml" { lines := []string{ fmt.Sprintf("owner: %q", f.Owner), - fmt.Sprintf("path: %q", f.Owner), + fmt.Sprintf("path: %q", f.Path), `content: {{ printf "%q" (regexReplaceAll "(name: address\n +value:).*" .kubeVipPodManifest (printf "$1 %s" .controlPlaneIpAddr)) }}`, fmt.Sprintf("permissions: %q", f.Permissions), } @@ -121,7 +121,6 @@ func TopologyPatch() clusterv1.ClusterClassPatch { } func fileToTemplate(f bootstrapv1.File) (string, error) { - out, err := yaml.Marshal(f) if err != nil { return "", errors.Wrapf(err, "unable to wrap file %q", f.Path) diff --git a/templates/clusterclass-template.yaml b/templates/clusterclass-template.yaml index b6c59ae6c9..19b16f8f99 100644 --- a/templates/clusterclass-template.yaml +++ b/templates/clusterclass-template.yaml @@ -128,7 +128,7 @@ spec: valueFrom: template: |- owner: "root:root" - path: "root:root" + path: "/etc/kubernetes/manifests/kube-vip.yaml" content: {{ printf "%q" (regexReplaceAll "(name: address\n +value:).*" .kubeVipPodManifest (printf "$1 %s" .controlPlaneIpAddr)) }} permissions: "0644" - op: add