Documentation ¶
Index ¶
- func BackupIfPresent(fs afero.Afero, basePath string, logger log.Logger, ui cli.Ui) error
- func BailIfPresent(fs afero.Afero, basePath string, logger log.Logger) error
- func FindOnlySubdir(dir string, fs afero.Afero) (string, error)
- func GenerateNameFromMetadata(k8sYaml MinimalK8sYaml, idx int) string
- func IsGithubURL(url string) bool
- func MaybeSplitMultidocYaml(ctx context.Context, fs afero.Afero, localPath string) error
- func NewKubernetesResource(in []byte) (*resource.Resource, error)
- type AssetUploader
- type CAType
- type CertType
- type GithubURL
- type List
- type MinimalK8sMetadata
- type MinimalK8sYaml
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BackupIfPresent ¶
func BailIfPresent ¶
BailIfPresent returns an error if the path is present. Handy to prevent accidentally blowing away directories on the workstation.
func FindOnlySubdir ¶
FindOnlySubdir finds the only subdirectory of a directory.
func GenerateNameFromMetadata ¶ added in v0.25.0
func GenerateNameFromMetadata(k8sYaml MinimalK8sYaml, idx int) string
func IsGithubURL ¶
returns true if this parses as a valid Github URL.
func MaybeSplitMultidocYaml ¶ added in v0.28.0
this function is not perfect, and has known limitations. One of these is that it does not account for `\n---\n` in multiline strings.
Types ¶
type AssetUploader ¶ added in v0.16.0
func NewAssetUploader ¶ added in v0.16.0
func NewAssetUploader( logger log.Logger, client *http.Client, ) AssetUploader
type List ¶ added in v0.26.0
type List struct { APIVersion string `json:"apiVersion" yaml:"apiVersion"` Path string `json:"path" yaml:"path"` Items []MinimalK8sYaml `json:"items" yaml:"items"` }
type MinimalK8sMetadata ¶ added in v0.26.0
type MinimalK8sYaml ¶ added in v0.26.0
type MinimalK8sYaml struct { Kind string `json:"kind" yaml:"kind" hcl:"kind"` Metadata MinimalK8sMetadata `json:"metadata" yaml:"metadata" hcl:"metadata"` }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.