Documentation
¶
Index ¶
- Constants
- Variables
- func AttachBoolArg(cmd *cobra.Command, parmType reflect.Type, variableName string, ...)
- func AttachIntArg(cmd *cobra.Command, parmType reflect.Type, variableName string, ...)
- func AttachStringArg(cmd *cobra.Command, parmType reflect.Type, variableName string, ...)
- func Command(program string, args []string, dir string, shortDesc string) (string, error)
- func DeleteAndVerifyNamespace(parms DeleteNamespaceParms, api corev1.CoreV1Interface) error
- func DownloadZipFromURL(url, destFile string) error
- func EnsureFowardSlashAtStringEnd(valDir string) string
- func GenerateFromGenericExampleWithHelmHandler(parms GenercExamplesDownloadParms) error
- func GenerateFromGenericQuickStartHandler(parms GenercQuickstartDownloadParms) (localTransformsCount int, err error)
- func LoadKubernetesAPI() (corev1.CoreV1Interface, error)
- func LoadURLInBrowser(url, oneWordDescription, optionalHint string) error
- func LogError(msg string)
- func LogExit(msg string)
- func LogInfo(msg string)
- func LogNotImplemented(msg string)
- func LogOK(msg string)
- func LogTime(msg string)
- func LogWaitingForUser(msg string)
- func LogWarn(msg string)
- func LogWorking(msg string)
- func MarkCommand(cmd *cobra.Command, parm interface{}, parmMap map[string]string, ...)
- func NewValidator() *validator.Validate
- func NonInteractiveAvailableURLMsg(url, oneWordDescription, credentials string)
- func UnzipFromFileToDir(src, dest string) (outputDir string, err error)
- func VerifyPodsReady(parms VerifyParms, api corev1.CoreV1Interface) error
- func WaitForSpaceBar()
- type Argument
- type DeleteNamespaceParms
- type GenercExamplesDownloadParms
- type GenercQuickstartDownloadParms
- type InstallParms
- type SimpleProjectObjectModel
- type SimpleProp
- type VerifyParms
Constants ¶
const DownloaderStereotypeExample = "stereotype-github-example"
const DownloaderStereotypeQuickstart = "stereotype-github-quickstart"
Variables ¶
var VerboseLogging bool
Functions ¶
func AttachBoolArg ¶
func AttachIntArg ¶
func AttachStringArg ¶
func AttachStringArg(cmd *cobra.Command, parmType reflect.Type, variableName string, variableValue *string, otherArgs ...string)
AttachStringArg uses reflection to read the provided struct to determine the arguments. otherArgs has the first argument is the defaultDefault value that overrides anything defined in the struct argument tag.
func DeleteAndVerifyNamespace ¶
func DeleteAndVerifyNamespace(parms DeleteNamespaceParms, api corev1.CoreV1Interface) error
DeleteAndVerifyNamespace deletes the namespace and verifies it is removed up to a timeout period
func DownloadZipFromURL ¶
func EnsureFowardSlashAtStringEnd ¶
EnsureFowardSlashAtStringEnd makes such "/" is at the end of a string (useful for file processing). Note: this isn't useful for all file systems, but good enough for Unix and Windows-style OSes.
func GenerateFromGenericExampleWithHelmHandler ¶
func GenerateFromGenericExampleWithHelmHandler(parms GenercExamplesDownloadParms) error
GenerateFromGenericExampleWithHelmHandler downloads and processes a template application from https://github.com/Activiti/example-runtime-bundle
func GenerateFromGenericQuickStartHandler ¶
func GenerateFromGenericQuickStartHandler(parms GenercQuickstartDownloadParms) (localTransformsCount int, err error)
GenerateFromGenericQuickStartHandler downloads and processes a template application from https://github.com/Activiti/activiti-cloud-runtime-bundle-quickstart/ or https://github.com/Activiti/activiti-cloud-connector-quickstart/
func LoadKubernetesAPI ¶
func LoadKubernetesAPI() (corev1.CoreV1Interface, error)
LoadKubernetesAPI loads Kubernetes api from the user's home directory and ".kube/config"
func LoadURLInBrowser ¶
func LogError ¶
func LogError(msg string)
LogError does Println with conditional ERROR prefix based on platform
func LogExit ¶
func LogExit(msg string)
LogExit does Println with conditional EXIT prefix based on platform and then ends the process with os.Exit(1)
func LogInfo ¶
func LogInfo(msg string)
LogInfo does Println with conditional INFO prefix based on platform
func LogNotImplemented ¶
func LogNotImplemented(msg string)
LogNotImplemented does Println with conditional UNFINISHED prefix based on platform
func LogTime ¶
func LogTime(msg string)
LogTime does Println with conditional TIME prefix based on platform
func LogWaitingForUser ¶
func LogWaitingForUser(msg string)
LogWaitingForUser does Println with conditional USERINPUT prefix based on platform
func LogWarn ¶
func LogWarn(msg string)
LogWarn does Println with conditional WARN prefix based on platform
func LogWorking ¶
func LogWorking(msg string)
LogWorking does Println with conditional WORKING prefix based on platform
func MarkCommand ¶
func NewValidator ¶
NewValidator instanciates a new validator.
func NonInteractiveAvailableURLMsg ¶
func NonInteractiveAvailableURLMsg(url, oneWordDescription, credentials string)
func UnzipFromFileToDir ¶
func VerifyPodsReady ¶
func VerifyPodsReady(parms VerifyParms, api corev1.CoreV1Interface) error
VerifyPodsReady looks at all of the pods in a namespace and confirms all services are running in the namespace running returning <nil> if successful. If the are not, the status is polled returning <nil> when the services are up-and-running or until the timeout period at which time an error is throw.
func WaitForSpaceBar ¶
func WaitForSpaceBar()
Types ¶
type Argument ¶
type Argument struct { Required bool LongName string ShortName string HasDefaultValue bool DefaultValue string }
func ParseArgFromField ¶
func ParseArgFromField(field reflect.StructField) (argument Argument, err error)
type DeleteNamespaceParms ¶
type DeleteNamespaceParms struct { Namespace string TimeoutSeconds int QueryForAllPodsRunningSeconds int }
DeleteNamespaceParms represents the parms for verifying that all of the pods in the namespace are running
type GenercQuickstartDownloadParms ¶
type GenercQuickstartDownloadParms struct { BundleName string PackageName string ProjectName string TagName string DestinationDir string DownloadURL string AdditionalTransCount int }
GenercQuickstartDownloadParms are parameters for download handling
type InstallParms ¶
type InstallParms struct { ChartName string CustomRepo bool HelmRepo string ValuesDir string Namespace string TimeoutSeconds int QueryForAllPodsRunningSeconds int }
InstallParms represent the parms for starting and verifying that all of the pods in the namespace are running
type SimpleProjectObjectModel ¶
type SimpleProjectObjectModel struct { GroupID string `xml:"groupId"` ArtifactID string `xml:"artifactId"` }
func GetProjectObjectModelFromCurrentDir ¶
func GetProjectObjectModelFromCurrentDir() (answer SimpleProjectObjectModel, err error)
type SimpleProp ¶
type SimpleProp struct {
SpringAppName string
}
func GetSimpleProp ¶
func GetSimpleProp(filePath string) (SimpleProp, error)
type VerifyParms ¶
VerifyParms represents the parms for verifying that all of the pods in the namespace are running