config

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ConfigPath string

Functions

func FindProjectConfig added in v0.5.1

func FindProjectConfig(config string) string

If a config file is specified, return it, otherwise try to find the nearest defaultConfigFile in parents

func GetAfterFunc

func GetAfterFunc() func(c *cli.Context) error

func GetBaseEnvVars

func GetBaseEnvVars() map[string]string

func GetBeforeFunc

func GetBeforeFunc() func(c *cli.Context) error

func GetEnvForCommand

func GetEnvForCommand(c *cli.Context) []string

func GetStacks added in v0.5.0

func GetStacks() []string

func ParseGlobalConfig

func ParseGlobalConfig()

func UseGoRun

func UseGoRun() bool

Types

type Config

type Config struct {
	// Global Configuration
	Env    map[string]string `yaml:"env,omitempty"`
	Before []string          `yaml:"before,omitempty"`
	After  []string          `yaml:"after,omitempty"`
	GoRun  bool              `yaml:"gorun,omitempty"`

	// Stacks configuration (includes subfolders)
	Stacks []string `yaml:"stacks,omitempty"`

	// Configuration for Commands
	Build   ContextConfig `yaml:"build,omitempty"`
	Export  ContextConfig `yaml:"export,omitempty"`
	Install ContextConfig `yaml:"install,omitempty"`
	Logs    ContextConfig `yaml:"logs,omitempty"`
	Ps      ContextConfig `yaml:"ps,omitempty"`
	Restart ContextConfig `yaml:"restart,omitempty"`
	Start   ContextConfig `yaml:"start,omitempty"`
	Stop    ContextConfig `yaml:"stop,omitempty"`
	Test    ContextConfig `yaml:"test,omitempty"`
}

type ContextConfig

type ContextConfig struct {
	Env    map[string]string `yaml:"env,omitempty"`
	Before []string          `yaml:"before,omitempty"`
	After  []string          `yaml:"after,omitempty"`
}

Jump to

Keyboard shortcuts

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