Documentation ¶
Index ¶
- func CleanupPatchAnnotations(patch []byte, name string) ([]byte, error)
- func JSONBytes(val interface{}) []byte
- func PtrBool(b bool) *bool
- func PtrInt64(i int64) *int64
- func PtrIntOrString(i intstr.IntOrString) *intstr.IntOrString
- func PtrString(s string) *string
- func RandomString(n int) string
- func ShortHash(data string, len int) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanupPatchAnnotations ¶
CleanupPatchAnnotations cleans up a patch diff to remove the kubekit annotations. This is useful for when a patch is applied and we don't want to print the annotations but just the actual diff.
func JSONBytes ¶
func JSONBytes(val interface{}) []byte
JSONBytes converts an interface value to a set of bytes encoded as JSON.
func PtrIntOrString ¶
func PtrIntOrString(i intstr.IntOrString) *intstr.IntOrString
PtrIntOrString converts a value of the intstr.IntOrString value to a pointer of that value.
func RandomString ¶
RandomString will return a string of length n with random characters.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.