Documentation ¶
Index ¶
- Variables
- func CelleryInstallationDir() string
- func CleanOrCreateDir(dirPath string) error
- func ContainsInStringArray(array []string, item string) bool
- func ConvertStringToTime(timeString string) time.Time
- func CopyDir(src string, dst string) error
- func CopyFile(src, dst string) error
- func CreateDir(dirPath string) error
- func DownloadFile(filepath string, url string) (*http.Response, error)
- func DownloadFromS3Bucket(bucket, item, path string, displayProgressBar bool)
- func ExecuteCommand(cmd *exec.Cmd, errorMessage string) error
- func ExecuteKubeCtlCmd(arg ...string) (string, error)
- func ExitWithErrorMessage(message string, err error)
- func ExtractTarGzFile(extractTo, archive_name string) error
- func FileExists(path string) (bool, error)
- func FileUploadRequest(uri string, params map[string]string, paramName, path string, secure bool) (*http.Request, error)
- func FindInDirectory(directory, suffix string) []string
- func FormatBytesToString(size int64) string
- func GetCurrentPath() (string, error)
- func GetDuration(startTime time.Time) string
- func GetFileSize(path string) (int64, error)
- func GetS3ObjectSize(bucket, item string) int64
- func GetSourceFileName(filePath string) (string, error)
- func GetSubDirectoryNames(path string) ([]string, error)
- func GetYesOrNoFromUser(question string, withBackOption bool) (bool, bool, error)
- func IsCompleteSetupSelected() (bool, bool)
- func IsLoadBalancerIngressTypeSelected() (bool, bool)
- func MergeKubeConfig(newConfigFile string) error
- func OpenBrowser(url string) error
- func PrintSuccessMessage(message string)
- func PrintWhatsNextMessage(action string, cmd string)
- func ReadCellImageYaml(cellImage string) []byte
- func RecursiveZip(files []string, folders []string, destinationPath string) error
- func RenameFile(oldName, newName string) error
- func ReplaceFile(fileToBeReplaced, fileToReplace string) error
- func ReplaceInFile(srcFile, oldString, newString string, replaceCount int) error
- func RequestCredentials(credentialType string, usernameOverride string) (string, string, error)
- func RunMethodExists(sourceFile string) (bool, error)
- func Trim(stream string) string
- func Unzip(zipFolderName string, destinationFolderName string) error
- func UserHomeDir() string
- func ValidateImageTag(imageTag string) error
- func ValidateImageTagWithRegistry(imageTag string) error
- func WaitForRuntime()
- func ZipFiles(filename string, files []string) error
- type BLangManager
- type Cell
- type CellAnnotations
- type CellImage
- type CellImageMetaData
- type CellImageName
- type CellList
- type CellMetaData
- type CellPods
- type CellSpec
- type CellStatus
- type ComponentTemplate
- type ComponentTemplateMetadata
- type Gateway
- type GatewayDefinition
- type GatewayGrpcApi
- type GatewayHttpApi
- type GatewaySpec
- type GatewayTcpApi
- type Gcp
- type GcpCompute
- type GcpCore
- type LangManager
- type Pod
- type PodCondition
- type PodMetaData
- type PodStatus
- type RegistryCredentials
- type Service
- type ServiceItem
- type ServiceMetaData
- type ServicePort
- type ServiceSpec
- type Spinner
Constants ¶
This section is empty.
Variables ¶
var Bold = color.New(color.Bold).SprintFunc()
var Faint = color.New(color.Faint).SprintFunc()
var Green = color.New(color.FgGreen).SprintfFunc()
Functions ¶
func CelleryInstallationDir ¶ added in v0.2.0
func CelleryInstallationDir() string
func CleanOrCreateDir ¶
func ContainsInStringArray ¶ added in v0.2.0
func ConvertStringToTime ¶
func DownloadFromS3Bucket ¶
func ExecuteKubeCtlCmd ¶ added in v0.2.0
executeKubeCtlCmd executes a command using the kubectl
func ExitWithErrorMessage ¶
ExitWithErrorMessage prints an error message and exits the command
func ExtractTarGzFile ¶
func FileExists ¶
func FileUploadRequest ¶
func FileUploadRequest(uri string, params map[string]string, paramName, path string, secure bool) (*http.Request, error)
Creates a new file upload http request with optional extra params
func FindInDirectory ¶
func FormatBytesToString ¶ added in v0.2.0
func GetCurrentPath ¶ added in v0.2.0
func GetDuration ¶
func GetFileSize ¶
func GetS3ObjectSize ¶ added in v0.2.0
func GetSourceFileName ¶
func GetSubDirectoryNames ¶
func GetYesOrNoFromUser ¶ added in v0.2.0
func IsCompleteSetupSelected ¶ added in v0.2.0
func IsLoadBalancerIngressTypeSelected ¶ added in v0.2.0
func MergeKubeConfig ¶ added in v0.2.0
func OpenBrowser ¶ added in v0.2.0
OpenBrowser opens up the provided URL in a browser
func PrintSuccessMessage ¶
func PrintSuccessMessage(message string)
PrintSuccessMessage prints the standard command success message
func PrintWhatsNextMessage ¶
func ReadCellImageYaml ¶ added in v0.2.0
func RecursiveZip ¶
func RenameFile ¶
func ReplaceFile ¶
func ReplaceInFile ¶
func RequestCredentials ¶
RequestCredentials requests the credentials form the user and returns them
func RunMethodExists ¶
RunMethodExists checks if the run method exists in ballerina file
func UserHomeDir ¶
func UserHomeDir() string
func ValidateImageTag ¶
ValidateImageTag validates the image tag (without the registry in it). This checks the version to be in the format of semantic versioning
func ValidateImageTagWithRegistry ¶
ValidateImageTag validates the image tag (with the registry in it). The registry is an option element in this validation. This checks the version to be in the format of semantic versioning
func WaitForRuntime ¶ added in v0.2.0
func WaitForRuntime()
Types ¶
type BLangManager ¶ added in v0.2.0
type BLangManager struct{}
func (*BLangManager) GetExecutablePath ¶ added in v0.2.0
func (langMgr *BLangManager) GetExecutablePath() (string, error)
func (*BLangManager) Init ¶ added in v0.2.0
func (langMgr *BLangManager) Init() error
type Cell ¶
type Cell struct { CellMetaData CellMetaData `json:"metadata"` CellSpec CellSpec `json:"spec"` CellStatus CellStatus `json:"status"` }
type CellAnnotations ¶ added in v0.2.0
type CellImage ¶
func ParseImageTag ¶
ParseImageTag parses the given image name string and returns a CellImage struct with the relevant information.
type CellImageMetaData ¶ added in v0.2.0
type CellImageMetaData struct { CellImageName BuildTimestamp int64 `json:"buildTimestamp"` Components []string `json:"components"` Dependencies map[string]*CellImageMetaData `json:"dependencies"` }
type CellImageName ¶ added in v0.2.0
type CellMetaData ¶
type CellMetaData struct { CreationTimestamp string `json:"creationTimestamp"` Annotations CellAnnotations `json:"annotations"` Name string `json:"name"` }
type CellSpec ¶ added in v0.2.0
type CellSpec struct { ComponentTemplates []ComponentTemplate `json:"servicesTemplates"` GateWayTemplate Gateway `json:"gatewayTemplate"` }
type CellStatus ¶
type ComponentTemplate ¶ added in v0.2.0
type ComponentTemplate struct {
Metadata ComponentTemplateMetadata `json:"metadata"`
}
type ComponentTemplateMetadata ¶ added in v0.2.0
type ComponentTemplateMetadata struct {
Name string `json:"name"`
}
type Gateway ¶
type Gateway struct {
GatewaySpec GatewaySpec `json:"spec"`
}
type GatewayDefinition ¶
type GatewayGrpcApi ¶ added in v0.2.0
type GatewayGrpcApi struct { Backend string `json:"backend"` Context string `json:"context"` Definitions []GatewayDefinition `json:"definitions"` Global bool `json:"global"` Vhost string `json:"vhost"` }
type GatewayHttpApi ¶
type GatewayHttpApi struct { Backend string `json:"backend"` Context string `json:"context"` Definitions []GatewayDefinition `json:"definitions"` Global bool `json:"global"` Vhost string `json:"vhost"` }
type GatewaySpec ¶
type GatewaySpec struct { HttpApis []GatewayHttpApi `json:"http"` TcpApis []GatewayTcpApi `json:"tcp"` GrpcApis []GatewayGrpcApi `json:"grpc"` }
type GatewayTcpApi ¶ added in v0.2.0
type GatewayTcpApi struct { Backend string `json:"backend"` Context string `json:"context"` Definitions []GatewayDefinition `json:"definitions"` Global bool `json:"global"` Vhost string `json:"vhost"` }
type Gcp ¶
type Gcp struct { Compute GcpCompute `json:"compute"` Core GcpCore `json:"core"` }
type GcpCompute ¶
type LangManager ¶ added in v0.2.0
type Pod ¶
type Pod struct { MetaData PodMetaData `json:"metadata"` PodStatus PodStatus `json:"status"` }
type PodCondition ¶
type PodMetaData ¶
type PodMetaData struct {
Name string `json:"name"`
}
type PodStatus ¶
type PodStatus struct { Phase string `json:"phase"` StartTime string `json:"startTime"` Conditions []PodCondition `json:"conditions"` }
type RegistryCredentials ¶ added in v0.2.0
type Service ¶
type Service struct {
Items []ServiceItem `json:"items"`
}
type ServiceItem ¶
type ServiceItem struct { Metadata ServiceMetaData `json:"metadata"` Spec ServiceSpec `json:"spec"` }
type ServiceMetaData ¶
type ServiceMetaData struct {
Name string `json:"name"`
}
type ServicePort ¶
type ServicePort struct {
Port int `json:"port"`
}
type ServiceSpec ¶
type ServiceSpec struct {
Ports []ServicePort `json:"ports"`
}
type Spinner ¶
type Spinner struct {
// contains filtered or unexported fields
}
func StartNewSpinner ¶
StartNewSpinner starts a new spinner with the provided message
func (*Spinner) Pause ¶ added in v0.2.0
func (s *Spinner) Pause()
Pause the spinner and clear the line
func (*Spinner) SetNewAction ¶
SetNewAction sets the current action of a spinner