config

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrDuplicateAccountName = errors.New("account with that name already exists")
	ErrInvalidAWSRegion     = errors.New("invalid AWS region")
	ErrMustContainAWSRegion = errors.New("account must contain at least one region")
)
View Source
var ValidRegions = []string{
	"us-east-1",
	"us-east-2",
	"us-west-1",
	"us-west-2",
	"ca-central-1",
	"eu-central-1",
	"eu-west-1",
	"eu-west-2",
	"eu-west-3",
	"eu-north-1",
	"sa-east-1",
	"ap-northeast-1",
	"ap-northeast-2",
	"ap-northeast-3",
	"ap-southeast-1",
	"ap-southeast-2",
	"ap-south-1",
}

Functions

This section is empty.

Types

type Config

type Config struct {
	Accounts []clusters.EKSAccount `yaml:"accounts"`
}

func NewConfig

func NewConfig() *Config

func (*Config) AddAccount

func (c *Config) AddAccount(account clusters.EKSAccount)

func (*Config) GetAccounts added in v1.0.0

func (c *Config) GetAccounts() []clusters.ClusterAccount

func (*Config) IsValidAccountName added in v0.0.6

func (c *Config) IsValidAccountName(name string) error

func (*Config) ListAccountNamesFiltered added in v0.0.6

func (c *Config) ListAccountNamesFiltered(excludeFilter []string) []string

func (*Config) ListAccountsFiltered added in v0.0.6

func (c *Config) ListAccountsFiltered(filter []string) []clusters.ClusterAccount

func (*Config) Validate

func (c *Config) Validate() error

func (*Config) Write

func (c *Config) Write() error

func (*Config) WriteToFile

func (c *Config) WriteToFile(filename string) error

Jump to

Keyboard shortcuts

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