Documentation ¶
Index ¶
- Constants
- Variables
- type Config
- func (c *Config) GetBuildOrderPaths() ([]string, error)
- func (c *Config) GetEnvDerivedPath() string
- func (c *Config) GetEnvTfPath() string
- func (c *Config) GetEnvValPath() string
- func (c *Config) IsBranch() bool
- func (c *Config) IsLeaf() bool
- func (c *Config) IsNotBranch() bool
- func (c *Config) IsNotLeaf() bool
- type ConfigFile
- type LoadConfigInput
Constants ¶
View Source
const ConfigFileComment = "## Generated by Colonize init\n---\n"
Variables ¶
View Source
var ConfigFileDefaults = ConfigFile{
"env",
"default",
"This file generated by colonize",
"_combined.tfvars",
"_combined_variables.tf",
"_combined_derived.tfvars",
"_combined_derived.tf",
"_combined.tf",
"_remote_setup.sh",
"remote_setup.sh",
"derived.tfvars",
".tfvars",
"build_order.txt",
}
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { // Inputs Environment string OriginPath string TmplName string TmplPath string CfgPath string RootPath string // Generated TmplRelPaths []string WalkablePaths []string WalkableValPaths []string CombinedValsFilePath string CombinedVarsFilePath string WalkableTfPaths []string CombinedTfFilePath string WalkableDerivedPaths []string CombinedDerivedValsFilePath string CombinedDerivedVarsFilePath string CombinedRemoteFilePath string RemoteFilePath string // Read in from config ConfigFile ConfigFile }
func LoadConfig ¶
func LoadConfig(input *LoadConfigInput) (*Config, error)
func (*Config) GetBuildOrderPaths ¶
func (*Config) GetEnvDerivedPath ¶
func (*Config) GetEnvTfPath ¶
func (*Config) GetEnvValPath ¶
func (*Config) IsNotBranch ¶
type ConfigFile ¶
type ConfigFile struct { Environments_Dir string "environments_dir" Base_Environment_Ext string "base_environment_ext" Autogenerate_Comment string "autogenerate_comment" Combined_Vals_File string "combined_vals_file" Combined_Vars_File string "combined_vars_file" Combined_Derived_Vals_File string "combined_derived_vals_file" Combined_Derived_Vars_File string "combined_derived_vars_file" Combined_Tf_File string "combined_tf_file" Combined_Remote_Config_File string "combined_remote_config_file" Remote_Config_File string "remote_config_file" Derived_File string "derived_file" Vals_File_Env_Post_String string "vals_file_env_post_string" Branch_Order_File string "branch_order_file" }
func (*ConfigFile) WriteToFile ¶
func (c *ConfigFile) WriteToFile(filename string) error
type LoadConfigInput ¶
type LoadConfigInput struct { // The environment Environment string // origin path where the command is run (typically cwd) OriginPath string // name for this template ie: vpc TmplName string // the difference between the cfg path and the root path. TmplPath string // path to config file CfgPath string // the root of the project (dir where config.yaml is) RootPath string }
Click to show internal directories.
Click to hide internal directories.