plan

package
v0.24.1 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2019 License: MIT Imports: 10 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Print

func Print(p *Plan) error

Print prints a plan

Types

type AWSBackend added in v0.21.0

type AWSBackend struct {
	AccountID   *string `yaml:"account_id,omitempty"`
	AccountName string  `yaml:"account_name"`
	Profile     string  `yaml:"profile"`
	Region      string  `yaml:"region"`
	Bucket      string  `yaml:"bucket"`
	DynamoTable *string `yaml:"dynamo_table"`
}

AWSBackend represents aws backend configuration

type AWSProfile added in v0.16.5

type AWSProfile struct {
	Name string
	ID   json.Number
	Role string
}

type AWSProvider added in v0.21.0

type AWSProvider struct {
	AccountID         json.Number `yaml:"account_id"`
	Profile           string      `yaml:"profile"`
	Version           string      `yaml:"version"`
	Region            string      `yaml:"region"`
	AdditionalRegions []string    `yaml:"additional_regions"`
}

type AWSRole added in v0.24.0

type AWSRole struct {
	AccountID string `yaml:"account_id"`
	RolePath  string `yaml:"role_path"`
	RoleName  string `yaml:"role_name"`
}

type Account added in v0.15.3

type Account struct {
	ComponentCommon `yaml:",inline"`

	AllAccounts map[string]json.Number `yaml:"all_accounts"`
	AccountName string                 `yaml:"account_name"`
	Global      *Component
}

Account is an account

type Atlantis added in v0.24.0

type Atlantis struct {
	Enabled  bool
	Projects []AtlantisProject

	// AWSProfiles is a map of profile name -> role info
	// TODO de-dupe this with AWSProfile in the travis-ci plan
	AWSProfiles map[string]AWSRole
}

type AtlantisComponent added in v0.24.0

type AtlantisComponent struct {
	Enabled  bool   `yaml:"enabled"`
	RoleName string `yaml:"role_name"`
	RolePath string `yaml:"role_path"`
}

type AtlantisProject added in v0.24.0

type AtlantisProject struct {
	Name             string `yaml:"name"`
	Dir              string `yaml:"dir"`
	TerraformVersion string `yaml:"terraform_version"`
	PathToRepoRoot   string `yaml:"path_to_repo_root"`
}

type BlessProvider added in v0.22.0

type BlessProvider struct {
	AdditionalRegions []string `yaml:"additional_regions,omitempty"`
	AWSProfile        string   `yaml:"aws_profile,omitempty"`
	AWSRegion         string   `yaml:"aws_region,omitempty"`
	Version           *string  `yaml:"version,omitempty"`
}

type Common added in v0.14.0

type Common struct {
	PathToRepoRoot   string `yaml:"path_to_repo_root"`
	TerraformVersion string `yaml:"terraform_version"`
}

Common represents common fields

type Component

type Component struct {
	ComponentCommon `yaml:",inline"`

	Accounts  map[string]Account // Reference accounts for remote state
	Component string
	EKS       *v1.EKSConfig `yaml:"eks,omitempty"`
	Env       string

	Kind            *v1.ComponentKind `yaml:"kind,omitempty"`
	ModuleSource    *string           `yaml:"module_source"`
	OtherComponents []string          `yaml:"other_components"`
	Global          *Component
}

Component is a component

type ComponentCommon added in v0.21.0

type ComponentCommon struct {
	Common `yaml:",inline"`

	Atlantis  AtlantisComponent `yaml:"atlantis"`
	Backend   AWSBackend        `yaml:"backend"`
	ExtraVars map[string]string `yaml:"extra_vars"`
	Owner     string
	Project   string
	Providers Providers `yaml:"providers"`
	TfLint    TfLint
}

type Env

type Env struct {
	Components map[string]Component
	Env        string
	EKS        *v1.EKSConfig //TODO get rid of this
}

Env is an env

type Module

type Module struct {
	Common `yaml:",inline"`
}

Module is a module

type OktaProvider added in v0.23.0

type OktaProvider struct {
	OrgName string  `json:"org_name,omitempty"`
	Version *string `json:"version,omitempty"`
}

type Plan

type Plan struct {
	Accounts map[string]Account
	Atlantis Atlantis
	Envs     map[string]Env
	Global   Component
	Modules  map[string]Module
	TravisCI TravisCI
	Version  string
}

Plan represents a set of actions to take

func Eval

func Eval(c *v2.Config) (*Plan, error)

Eval evaluates a config

type Providers added in v0.21.0

type Providers struct {
	AWS       *AWSProvider       `yaml:"aws"`
	Snowflake *SnowflakeProvider `yaml:"snowflake"`
	Bless     *BlessProvider     `yaml:"bless"`
	Okta      *OktaProvider      `yaml:"okta"`
}

type SnowflakeProvider added in v0.21.0

type SnowflakeProvider struct {
	Account string  `yaml:"account,omitempty"`
	Role    string  `yaml:"role,omitempty"`
	Region  string  `yaml:"region,omitempty"`
	Version *string `yaml:"version,omitempty"`
}

type TfLint added in v0.14.0

type TfLint struct {
	Enabled bool
}

TfLint containts a plan for running tflint

type TravisCI added in v0.16.5

type TravisCI struct {
	AWSProfiles []AWSProfile
	Enabled     bool
	FoggVersion string
	TestBuckets [][]string
}

Jump to

Keyboard shortcuts

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