model

package
v0.3.17-rc28 Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2023 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StepTypeTerraform       StepType = "terraform"
	StepTypeArgoCD                   = "argocd-apps"
	StepTypeTerraformCustom          = "terraform-custom"
)
View Source
const (
	ApproveMinor  Approve = "minor"
	ApproveMajor          = "major"
	ApproveAlways         = "always"
	ApproveNever          = "never"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Approve

type Approve string

type BaseConfig

type BaseConfig struct {
	Version string `yaml:"version,omitempty"`
	Profile string `yaml:"profile"`
}

type Config

type Config struct {
	BaseConfig   BaseConfig `yaml:"base_config"`
	Prefix       string     `yaml:"prefix,omitempty"`
	Source       string     `yaml:"source"`
	Version      string     `yaml:"version,omitempty"`
	AgentVersion string     `yaml:"agent_version,omitempty"`
	Steps        []Step     `yaml:"steps,omitempty"`
}

type Module

type Module struct {
	Name    string                 `yaml:"name"`
	Source  string                 `yaml:"source,omitempty"`
	Version string                 `yaml:"version,omitempty"`
	Remove  bool                   `yaml:"remove,omitempty"`
	Inputs  map[string]interface{} `yaml:"inputs,omitempty"`
}

type Set

type Set[T comparable] map[T]bool

func NewSet

func NewSet[T comparable]() Set[T]

func (Set[T]) Add

func (s Set[T]) Add(item T)

func (Set[T]) Contains

func (s Set[T]) Contains(item T) bool

func (Set[T]) Remove

func (s Set[T]) Remove(item T)

func (Set[T]) Size

func (s Set[T]) Size() int

func (Set[T]) ToSlice

func (s Set[T]) ToSlice() []T

type State

type State struct {
	Steps []*StateStep `yaml:"steps"`
}

type StateModule

type StateModule struct {
	Name        string           `yaml:"name"`
	Version     *version.Version `yaml:"version,omitempty"`
	AutoApprove bool             `yaml:"-"` // always omit
}

type StateStep

type StateStep struct {
	Name      string         `yaml:"name"`
	Workspace string         `yaml:"workspace"`
	AppliedAt time.Time      `yaml:"applied_at,omitempty"`
	Modules   []*StateModule `yaml:"modules"`
}

type Step

type Step struct {
	Name         string   `yaml:"name"`
	Type         StepType `yaml:"type,omitempty"`
	Workspace    string   `yaml:"workspace"`
	Approve      Approve  `yaml:"approve,omitempty"`
	Remove       bool     `yaml:"remove,omitempty"`
	Version      string   `yaml:"version,omitempty"`
	VpcPrefix    string   `yaml:"vpc_prefix,omitempty"`
	ArgoCDPrefix string   `yaml:"argocd_prefix,omitempty"`
	Modules      []Module `yaml:"modules,omitempty"`
}

type StepType

type StepType string

Jump to

Keyboard shortcuts

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