Documentation
¶
Index ¶
- Constants
- func Dump() ([]byte, error)
- type CMD
- type Config
- func (cfg Config) GetAnsibleDirectory(env Environment) string
- func (cfg Config) GetMyIP() (string, error)
- func (cfg Config) GetPath(env Environment) string
- func (cfg Config) GetProfile(env string) string
- func (cfg Config) IsAWSA(env string) bool
- func (cfg Config) IsCI(env string) bool
- func (cfg Config) IsLive(env string) bool
- func (cfg Config) IsNisra(env string) bool
- func (cfg Config) IsSecure(env string) bool
- type Environment
- type ExtraPorts
Constants ¶
View Source
const ( TAG_AWSA = "awsa" // legacy/deprecated TAG_CI = "ci" // concourse TAG_LIVE = "live" // production TAG_SECURE = "secure" // has secure data (e.g. prod, staging) TAG_NISRA = "nisra" // NISRA )
tags refer to dp-cli-config.yml environment tags which put that environment into group types
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { CMD CMD `yaml:"cmd"` Environments []Environment `yaml:"environments"` SSHUser *string `yaml:"ssh-user"` UserName *string `yaml:"user-name"` IPAddress *string `yaml:"ip-address"` HttpOnly *bool `yaml:"http-only"` DPSetupPath string `yaml:"dp-setup-path"` NisraPath string `yaml:"dp-nisra-path"` DPCIPath string `yaml:"dp-ci-path"` DPHierarchyBuilderPath string `yaml:"dp-hierarchy-builder-path"` DPCodeListScriptsPath string `yaml:"dp-code-list-scripts-path"` DPCLIPath string `yaml:"dp-cli-path"` }
func (Config) GetAnsibleDirectory ¶
func (cfg Config) GetAnsibleDirectory(env Environment) string
func (Config) GetMyIP ¶
GetMyIP returns first IP in: `--ip` flag, `MY_IP` env var, config file, external service
func (Config) GetPath ¶
func (cfg Config) GetPath(env Environment) string
func (Config) GetProfile ¶
type Environment ¶
type Environment struct { Name string `yaml:"name"` Profile string `yaml:"profile"` SSHUser string `yaml:"ssh-user"` Tags []string `yaml:"tags"` ExtraPorts ExtraPorts `yaml:"extra-ports"` }
Environment represents an environment
func (Environment) IsAWSA ¶
func (env Environment) IsAWSA() bool
func (Environment) IsCI ¶
func (env Environment) IsCI() bool
func (Environment) IsLive ¶
func (env Environment) IsLive() bool
func (Environment) IsNisra ¶
func (env Environment) IsNisra() bool
func (Environment) IsSecure ¶ added in v0.54.0
func (env Environment) IsSecure() bool
type ExtraPorts ¶
type ExtraPorts struct { Bastion []int64 `yaml:"bastion"` Publishing []int64 `yaml:"publishing"` Web []int64 `yaml:"web"` }
ExtraPorts is a list of ports for the given Security Group
Click to show internal directories.
Click to hide internal directories.