generated

package
v1.1.1-0...-9418116 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ConfigPath = ".devspace/generated.yaml"

ConfigPath is the relative generated config path

Functions

func InitDevSpaceConfig

func InitDevSpaceConfig(config *Config, configName string)

InitDevSpaceConfig verifies a given config name is set

Types

type CacheConfig

type CacheConfig struct {
	Deployments  map[string]*DeploymentCache `yaml:"deployments,omitempty"`
	Images       map[string]*ImageCache      `yaml:"images,omitempty"`
	Dependencies map[string]string           `yaml:"dependencies,omitempty"`
	LastContext  *LastContextConfig          `yaml:"lastContext,omitempty"`
}

CacheConfig holds all the information specific to a certain config

func NewCache

func NewCache() *CacheConfig

NewCache returns a new cache object

func (*CacheConfig) GetDeploymentCache

func (cache *CacheConfig) GetDeploymentCache(deploymentName string) *DeploymentCache

GetDeploymentCache returns the deployment cache if it exists and creates one if not

func (*CacheConfig) GetImageCache

func (cache *CacheConfig) GetImageCache(imageConfigName string) *ImageCache

GetImageCache returns the image cache if it exists and creates one if not

type Config

type Config struct {
	OverrideProfile *string                 `yaml:"lastOverrideProfile,omitempty"`
	ActiveProfile   string                  `yaml:"activeProfile,omitempty"`
	Vars            map[string]string       `yaml:"vars,omitempty"`
	Profiles        map[string]*CacheConfig `yaml:"profiles,omitempty"`
}

Config specifies the runtime config struct

func (*Config) GetActive

func (config *Config) GetActive() *CacheConfig

GetActive returns the currently active devspace config

func (*Config) GetActiveProfile

func (config *Config) GetActiveProfile() string

GetActiveProfile returns the active profile

type ConfigLoader

type ConfigLoader interface {
	Load() (*Config, error)
	LoadFromPath(path string) (*Config, error)
	Save(config *Config) error
}

ConfigLoader is the interface for loading the generated config

func NewConfigLoader

func NewConfigLoader(profile string) ConfigLoader

NewConfigLoader creates a new generated config loader

type DeploymentCache

type DeploymentCache struct {
	DeploymentConfigHash string `yaml:"deploymentConfigHash,omitempty"`

	HelmOverridesHash    string `yaml:"helmOverridesHash,omitempty"`
	HelmChartHash        string `yaml:"helmChartHash,omitempty"`
	KubectlManifestsHash string `yaml:"kubectlManifestsHash,omitempty"`
}

DeploymentCache holds the information about a specific deployment

type ImageCache

type ImageCache struct {
	ImageConfigHash string `yaml:"imageConfigHash,omitempty"`

	DockerfileHash string `yaml:"dockerfileHash,omitempty"`
	ContextHash    string `yaml:"contextHash,omitempty"`
	EntrypointHash string `yaml:"entrypointHash,omitempty"`

	CustomFilesHash string `yaml:"customFilesHash,omitempty"`

	ImageName string `yaml:"imageName,omitempty"`
	Tag       string `yaml:"tag,omitempty"`
}

ImageCache holds the cache related information about a certain image

type LastContextConfig

type LastContextConfig struct {
	Namespace string `yaml:"namespace,omitempty"`
	Context   string `yaml:"context,omitempty"`
}

LastContextConfig holds all the informations about the last used kubernetes context

Jump to

Keyboard shortcuts

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