...

Package utils

import "github.com/GoogleCloudPlatform/k8s-config-connector/operator/scripts/utils"
Overview
Index

Overview ▾

func BytesToUnstruct

func BytesToUnstruct(bytes []byte) (*unstructured.Unstructured, error)

func Copy

func Copy(source, dest string) error

func DownloadAndExtractTarballAt

func DownloadAndExtractTarballAt(gcsPath, outputDir string) error

func DownloadObjectFromGCS

func DownloadObjectFromGCS(gcsPath, outputDir string) error

func Execute

func Execute(cmd *exec.Cmd) error

func ExecuteAndCaptureOutput

func ExecuteAndCaptureOutput(cmd *exec.Cmd) (stdout string, err error)

func ExtractTarball

func ExtractTarball(tarballPath, outputDir string) error

func KustomizeBuild

func KustomizeBuild(path, output string) error

func ReadFileToUnstructs

func ReadFileToUnstructs(filePath string) ([]*unstructured.Unstructured, error)

func SplitYAML

func SplitYAML(yamlBytes []byte) ([][]byte, error)

func UnstructToYaml

func UnstructToYaml(u *unstructured.Unstructured) ([]byte, error)