Documentation
¶
Index ¶
- Variables
- func AddTpTemp(file string)
- func Cleanup() error
- func CloseQuietly(d io.Closer)
- func ConfigureNginx(args LoadBalancerArgs) error
- func GenKubeconfig(bindIP string) error
- func HaveController(controllers string, c string) bool
- func IfDeployByPod(controllers string) bool
- func KillNginx() error
- func LinkToVela()
- func LoadVelaImages() error
- func NewInstallCmd(c common.Args, ioStreams cmdutil.IOStreams) *cobra.Command
- func NewKubeConfigCmd() *cobra.Command
- func NewLBInstallCmd() *cobra.Command
- func NewLBUninstallCmd() *cobra.Command
- func NewLoadBalancerCmd() *cobra.Command
- func NewTokenCmd() *cobra.Command
- func NewUninstallCmd() *cobra.Command
- func NewVeladCommand() *cobra.Command
- func NewVersionCmd() *cobra.Command
- func PrepareK3sBin() error
- func PrepareK3sImages() error
- func PrepareK3sScript() (string, error)
- func PrepareVelaChart() (string, error)
- func PrintKubeConfig(internal, external bool)
- func SaveToTemp(file fs.File, format string) (string, error)
- func SetupK3s(cArgs InstallArgs) error
- func TransArgsToString(args cli.InstallArgs) []string
- func UninstallNginx() error
- func WarnSaveToken(token string)
- type App
- type InstallArgs
- type LoadBalancerArgs
Constants ¶
This section is empty.
Variables ¶
View Source
var ( KubeConfigLocation = "/etc/rancher/k3s/k3s.yaml" ExternalKubeConfigLocation = "/etc/rancher/k3s/k3s-external.yaml" VelaLinkPos = "/usr/local/bin/vela" )
Functions ¶
func CloseQuietly ¶
CloseQuietly closes `io.Closer` quietly. Very handy and helpful for code quality too.
func ConfigureNginx ¶ added in v1.3.1
func ConfigureNginx(args LoadBalancerArgs) error
func GenKubeconfig ¶
GenKubeconfig will generate kubeconfig for remote access. This won't modify the origin kubeconfig generated by k3s
func HaveController ¶
func IfDeployByPod ¶
func LoadVelaImages ¶
func LoadVelaImages() error
func NewInstallCmd ¶
NewInstallCmd create install cmd
func NewKubeConfigCmd ¶
NewKubeConfigCmd create kubeconfig command for ctrl-plane
func NewLBInstallCmd ¶ added in v1.3.1
func NewLBUninstallCmd ¶ added in v1.3.1
func NewLoadBalancerCmd ¶ added in v1.3.1
func NewTokenCmd ¶
func NewUninstallCmd ¶
NewUninstallCmd create uninstall command
func NewVersionCmd ¶
func PrepareK3sScript ¶
PrepareK3sScript Write k3s install script to local
func PrepareVelaChart ¶
func PrintKubeConfig ¶ added in v1.3.1
func PrintKubeConfig(internal, external bool)
func SaveToTemp ¶
SaveToTemp helps save an embedded file into a temporary file
func TransArgsToString ¶
func TransArgsToString(args cli.InstallArgs) []string
func UninstallNginx ¶ added in v1.3.1
func UninstallNginx() error
func WarnSaveToken ¶
func WarnSaveToken(token string)
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
App is entry of all CLI, created by NewApp
type InstallArgs ¶ added in v1.3.1
type InstallArgs struct {
BindIP string
DBEndpoint string
IsStart bool
Token string
Controllers string
// InstallArgs is parameters passed to vela install command
InstallArgs cli.InstallArgs
}
InstallArgs defines arguments for velad install command
type LoadBalancerArgs ¶ added in v1.3.1
LoadBalancerArgs defines arguments for load balancer command
Click to show internal directories.
Click to hide internal directories.