Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AppContext ¶
type AppContext interface { // WorkingDir returns path of the directory from where // the application was executed. WorkingDir() string // HomeDir returns path of the directory where cluster // configuration files and related dependencies are // stored. // // Default is "$HOME/.kubitect". HomeDir() string // that are shared among all clusters are stored. // // Default is "$HOME/.kubitect/share" ShareDir() string // ClustersDir returns path of the directory where // clusters are created. // // Default is "$HOME/.kubitect/clusters". ClustersDir() string // LocalClustersDir returns path of the directory where // local clusters are created. // // Default is "./.kubitect/clusters". LocalClustersDir() string // Local indicates that all cluster actions should be // executed within working directory. Local() bool // ShowTerraformPlan indicates that terraform plan should // be always shown. ShowTerraformPlan() bool }
type AppContextMock ¶
type AppContextMock interface { AppContext Ui() ui.UiMock Options() AppContextOptions }
func MockAppContext ¶
func MockAppContext(t *testing.T, opts ...AppContextOptions) AppContextMock
type AppContextOptions ¶
type AppContextOptions struct { // Automatically approve user prompts AutoApprove bool // Show debug messages Debug bool // Disable color in output NoColor bool // Local deployment. Use working dir as project home dir. Local bool // Show terraform plan ShowTerraformPlan bool // contains filtered or unexported fields }
func (AppContextOptions) AppContext ¶
func (o AppContextOptions) AppContext() AppContext
NewAppContext creates new application context and initializes a global UI.
Click to show internal directories.
Click to hide internal directories.