Documentation
¶
Index ¶
- Variables
- func AddStackCompletion(cmd *cobra.Command)
- func CheckForAtmosUpdateAndPrintMessage(atmosConfig schema.AtmosConfiguration)
- func ComponentsArgCompletion(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective)
- func Contains(slice []string, target string) bool
- func Execute() error
- type AtmosValidateOption
- type ExampleContent
- type ValidateConfig
Constants ¶
This section is empty.
Variables ¶
View Source
var RootCmd = &cobra.Command{ Use: "atmos", Short: "Universal Tool for DevOps and Cloud Automation", Long: `Atmos is a universal tool for DevOps and cloud automation used for provisioning, managing and orchestrating workflows across various toolchains`, FParseErrWhitelist: cobra.FParseErrWhitelist{UnknownFlags: true}, PersistentPreRun: func(cmd *cobra.Command, args []string) { isHelpCommand := cmd.Name() == "help" helpFlag := cmd.Flags().Changed("help") isHelpRequested := isHelpCommand || helpFlag if isHelpRequested { cmd.SilenceUsage = false cmd.SilenceErrors = false } else { cmd.SilenceUsage = true cmd.SilenceErrors = true } configAndStacksInfo := schema.ConfigAndStacksInfo{} if cmd.Flags().Changed("logs-level") { logsLevel, _ := cmd.Flags().GetString("logs-level") configAndStacksInfo.LogsLevel = logsLevel } if cmd.Flags().Changed("logs-file") { logsFile, _ := cmd.Flags().GetString("logs-file") configAndStacksInfo.LogsFile = logsFile } _, err := cfg.InitCliConfig(configAndStacksInfo, false) if err != nil { if errors.Is(err, cfg.NotFound) { if !isHelpRequested { u.LogWarning(err.Error()) } } else { u.LogErrorAndExit(err) } } }, Run: func(cmd *cobra.Command, args []string) { checkAtmosConfig() fmt.Println() err := tuiUtils.PrintStyledText("ATMOS") if err != nil { u.PrintErrorMarkdownAndExit("", err, "") } err = e.ExecuteAtmosCmd() if err != nil { u.LogErrorAndExit(err) } }, }
RootCmd represents the base command when called without any subcommands
View Source
var ValidateStacksCmd = &cobra.Command{ Use: "stacks", Short: "Validate stack manifest configurations", Long: "This command validates the configuration of stack manifests in Atmos to ensure proper setup and compliance.", Example: "validate stacks", FParseErrWhitelist: struct{ UnknownFlags bool }{UnknownFlags: false}, Args: cobra.NoArgs, Run: func(cmd *cobra.Command, args []string) { checkAtmosConfig() err := e.ExecuteValidateStacksCmd(cmd, args) if err != nil { u.PrintErrorMarkdownAndExit("", err, "") } u.PrintMessageInColor("all stacks validated successfully\n", theme.Colors.Success) }, }
ValidateStacksCmd validates stacks
Functions ¶
func AddStackCompletion ¶ added in v1.161.0
func CheckForAtmosUpdateAndPrintMessage ¶ added in v1.127.0
func CheckForAtmosUpdateAndPrintMessage(atmosConfig schema.AtmosConfiguration)
CheckForAtmosUpdateAndPrintMessage checks if a version update is needed and prints a message if a newer version is found. It loads the cache, decides if it's time to check for updates, compares the current version to the latest available release, and if newer, prints the update message. It also updates the cache's timestamp after printing.
func ComponentsArgCompletion ¶ added in v1.161.0
Types ¶
type AtmosValidateOption ¶ added in v1.97.0
type AtmosValidateOption func(*ValidateConfig)
func WithStackValidation ¶ added in v1.97.0
func WithStackValidation(check bool) AtmosValidateOption
type ExampleContent ¶ added in v1.162.0
type ValidateConfig ¶ added in v1.97.0
type ValidateConfig struct {
CheckStack bool
}
ValidateConfig holds configuration options for Atmos validation. CheckStack determines whether stack configuration validation should be performed.
Source Files
¶
- about.go
- atlantis.go
- atlantis_generate.go
- atlantis_generate_repo_config.go
- aws.go
- aws_eks.go
- aws_eks_update_kubeconfig.go
- cmd_utils.go
- completion.go
- describe.go
- describe_affected.go
- describe_component.go
- describe_config.go
- describe_dependents.go
- describe_stacks.go
- describe_workflows.go
- docs.go
- helmfile.go
- helmfile_apply.go
- helmfile_destroy.go
- helmfile_diff.go
- helmfile_generate.go
- helmfile_generate_varfile.go
- helmfile_sync.go
- list.go
- list_components.go
- list_stacks.go
- list_workflows.go
- markdown_help.go
- pro.go
- pro_lock.go
- pro_unlock.go
- root.go
- support.go
- terraform.go
- terraform_commands.go
- terraform_generate.go
- terraform_generate_backend.go
- terraform_generate_backends.go
- terraform_generate_varfile.go
- terraform_generate_varfiles.go
- validate.go
- validate_component.go
- validate_editorconfig.go
- validate_stacks.go
- vendor.go
- vendor_diff.go
- vendor_pull.go
- version.go
- workflow.go
Click to show internal directories.
Click to hide internal directories.