common

package
v0.9.25 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 18, 2024 License: MIT Imports: 42 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AffirmUp   = "" /* 139-byte string literal not displayed */
	AffirmDown = "Are you ready to destroy your plural infrastructure?  This will destroy all k8s clusters and any data stored within"
)
View Source
const (
	GitAttributesFile = ".gitattributes"
	GitIgnoreFile     = ".gitignore"
)
View Source
const BackupMsg = "" /* 126-byte string literal not displayed */
View Source
const Gitattributes = `` /* 756-byte string literal not displayed */
View Source
const Gitignore = `/**/.terraform
/**/.terraform*
/**/terraform.tfstate*
/bin
*~
.idea
*.swp
*.swo
.DS_STORE
.vscode
`

Variables

View Source
var (
	ErrNoGit      = fmt.Errorf("Could not compare current workspace to origin. Do you have an `origin` remote configured, or does your repo not have an initial commit?")
	ErrRemoteDiff = fmt.Errorf("Your local workspace is not in sync with remote. Either `git pull` recent changes or `git push` any missed changes.  Also confirm you can authenticate to the origin remote, which you can see with `git remote -v`")
	ErrUnlock     = fmt.Errorf("could not decrypt your repo, this is likely due to using the wrong key at ~/.plural/key. The original key might be in a backup or on your previous machine.")
)
View Source
var (
	Version = versionPlaceholder
	Commit  = ""
	Date    = ""
)
View Source
var BootstrapMode bool

Functions

func Affirm

func Affirm(msg string, envKey string) bool

func Affirmed

func Affirmed(fn func(*cli.Context) error, msg string, envKey string) func(*cli.Context) error

func AppReadme

func AppReadme(name string, dryRun bool) error

func Apply

func Apply(c *cli.Context) error

func CaptureStdout

func CaptureStdout(app *cli.App, arg []string) (string, error)

func CommitMsg

func CommitMsg(c *cli.Context) string

func Confirm

func Confirm(msg string, envKey string) bool

func CryptoInit

func CryptoInit(c *cli.Context) error

func Diffed

func Diffed(_ *cli.Context) error

func DoBuild

func DoBuild(client api.Client, installation *api.Installation, force bool) error

func DownloadReadme

func DownloadReadme(c *cli.Context) error

func GetIdAndName

func GetIdAndName(input string) (id, name *string)

func GitCommand

func GitCommand(args ...string) *exec.Cmd

func GitConfig

func GitConfig(name, val string) error

func HandleClone

func HandleClone(c *cli.Context) error

func HandleDiff

func HandleDiff(_ *cli.Context) error

func HandleDown

func HandleDown(_ *cli.Context) error

func HandleHelmTemplate

func HandleHelmTemplate(c *cli.Context) error

func HandleImport

func HandleImport(c *cli.Context) error

func HandleInfo

func HandleInfo(c *cli.Context) error

func HandleLogin

func HandleLogin(c *cli.Context) error

func HandleRepair

func HandleRepair(c *cli.Context) error

func HandleScaffold

func HandleScaffold(c *cli.Context) error

func HandleServe

func HandleServe(c *cli.Context) error

func HandleUnlock

func HandleUnlock(_ *cli.Context) error

func HandleWait

func HandleWait(c *cli.Context) error

func HandleWatch

func HandleWatch(c *cli.Context) error

func Highlighted

func Highlighted(fn func(*cli.Context) error) func(*cli.Context) error

func InitKubeconfig

func InitKubeconfig(fn func(*cli.Context) error) func(*cli.Context) error

func KubeInit

func KubeInit(_ *cli.Context) error

func LatestVersion

func LatestVersion(fn func(*cli.Context) error) func(*cli.Context) error

func Owned

func Owned(fn func(*cli.Context) error) func(*cli.Context) error

func Preflights

func Preflights(c *cli.Context) error

func PrintListNodes

func PrintListNodes(nodes *v1.NodeList) error

func RepoRoot

func RepoRoot() error

func RequireArgs

func RequireArgs(fn func(*cli.Context) error, args []string) func(*cli.Context) error

func RequireKind

func RequireKind(fn func(*cli.Context) error) func(*cli.Context) error

func Rooted

func Rooted(fn func(*cli.Context) error) func(*cli.Context) error

func RunPreflights

func RunPreflights(c *cli.Context) (provider.Provider, error)

func TestTemplate

func TestTemplate(c *cli.Context) error

func Tracked

func Tracked(fn func(*cli.Context) error, event string) func(*cli.Context) error

func UpstreamSynced

func UpstreamSynced(fn func(*cli.Context) error) func(*cli.Context) error

func ValidateOwner

func ValidateOwner() error

func VersionInfo

func VersionInfo(_ *cli.Context) error

func VersionValid

func VersionValid(vsn string) bool

Types

type GrafanaDashboard

type GrafanaDashboard struct {
	Title  string
	Panels []struct {
		Title   string
		Targets []struct {
			Expr         string
			LegendFormat string
		}
	}
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL