Documentation ¶
Index ¶
- Variables
- func AllComponents(config DeploymentConfig, environ string) error
- func Component(config DeploymentConfig, component, envName string) error
- func CreateDeployDirectory(environ string) error
- func CreateDirIfNotExists(path string) error
- func DestroyAllComponents(config DeploymentConfig, envName string) error
- func DestroyComponent(component, envName string) error
- func FindAndReplace(filename, original, replacement string) error
- func SetS3Backend(d DeploymentConfig, component string) error
- func UserAwsCredFile() (string, error)
- func Wizard() error
- type DeploymentConfig
Constants ¶
This section is empty.
Variables ¶
var ( // DeployOrder dictates what order the deployed components should happen in DeployOrder = []string{ vpc, datastore, firehose, configs, secrets, autoscaling, carver, } ElasticDeployOrder = []string{ vpc, datastore, elasticsearch, elasticsearchFirehose, elasticsearchConfig, secrets, elasticsearchAutoscaling, carver, } // OsqueryOpts holds all deploy options for osquery OsqueryOpts = []string{ packs, configs, scripts, } )
Functions ¶
func AllComponents ¶
func AllComponents(config DeploymentConfig, environ string) error
AllComponents deploys all components
func Component ¶
func Component(config DeploymentConfig, component, envName string) error
Component deploys both aws components and osquery components
func CreateDeployDirectory ¶
CreateDeployDirectory Creates deployment director based on environment
func CreateDirIfNotExists ¶
CreateDirIfNotExists creates directory if it does not exist
func DestroyAllComponents ¶
func DestroyAllComponents(config DeploymentConfig, envName string) error
DestroyAllComponents destroys all components, in reverse order
func DestroyComponent ¶
DestroyComponent is a wrapper to match the `deploy.Component` interface style
func FindAndReplace ¶
FindAndReplace finds a string and resplaces it with replacement
func SetS3Backend ¶
func SetS3Backend(d DeploymentConfig, component string) error
func UserAwsCredFile ¶
UserAwsCredFile returns a users aws credential file from their home dir
Types ¶
type DeploymentConfig ¶
type DeploymentConfig struct { Environment string `json:"environment"` AWSProfile string `json:"aws_profile"` UserIPAddress string `json:"user_ip_address"` SgtOsqueryResultsBucketName string `json:"sgt_osquery_results_bucket_name"` SgtConfigBucketName string `json:"sgt_config_bucket_name"` Domain string `json:"domain"` Subdomain string `json:"subdomain"` AwsKeypair string `json:"aws_keypair"` FullSslCertchain string `json:"full_ssl_certchain"` SslPrivateKey string `json:"ssl_private_key"` SgtNodeSecret string `json:"sgt_node_secret"` SgtAppSecret string `json:"sgt_app_secret"` CreateElasticsearch int `json:"create_elasticsearch"` AsgDesiredSize int `json:"asg_desired_size"` AWSRegion string `json:"aws_region"` Users []string `json:"users"` MailDomain string `json:"mail_domain"` TerraformBackendBucketName string `json:"terraform_backend_bucket_name"` AutoApproveNodes string `json:"auto_approve_nodes"` }
DeploymentConfig configuration file used by all environment deployments
func ParseDeploymentConfig ¶
func ParseDeploymentConfig(environ string) (DeploymentConfig, error)
ParseDeploymentConfig returns the loaded config given its path on disk or exits with status 1 on failure