config

package
v0.0.21 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ValidateConfig

func ValidateConfig(cfg *Config) error

Types

type BootstrapConfig added in v0.0.20

type BootstrapConfig struct {
	Run     []string `yaml:"run"`
	Timeout int      `yaml:"timeout,omitempty"`
}

type CacheConfig

type CacheConfig struct {
	Key   string   `yaml:"key"`
	Paths []string `yaml:"paths"`
}

type Config

type Config struct {
	FileName        string
	Stages          []string          `yaml:"stages"`
	Jobs            []JobConfig       `yaml:"-"`
	GlobalVariables map[string]string `yaml:"variables,omitempty"`
	RemoteProvider  *RemoteProvider   `yaml:"remote_provider,omitempty"`
	CLIVariables    map[string]string `yaml:"-"`
	Bootstrap       *BootstrapConfig  `yaml:"bootstrap,omitempty"`
}

func NewConfig

func NewConfig(file string) *Config

func (*Config) LoadConfig

func (c *Config) LoadConfig() error

func (*Config) UnmarshalYAML added in v0.0.17

func (c *Config) UnmarshalYAML(node *yaml.Node) error

type JobConfig

type JobConfig struct {
	Name      string            `yaml:"-"`
	Image     string            `yaml:"image"`
	Script    []string          `yaml:"script"`
	Stage     string            `yaml:"stage"`
	Workdir   string            `yaml:"workdir,omitempty"`
	Variables map[string]string `yaml:"variables,omitempty"`
	Cache     *CacheConfig      `yaml:"cache,omitempty"`
	Network   *NetworkConfig    `yaml:"network,omitempty"`
}

type NetworkConfig added in v0.0.8

type NetworkConfig struct {
	HostAccess bool `yaml:"host_access,omitempty"`
	HostMode   bool `yaml:"host_mode,omitempty"`
}

type RemoteProvider added in v0.0.17

type RemoteProvider struct {
	Url       string `yaml:"url"`
	ProjectId int    `yaml:"project_id"`
	Token     string `yaml:"access_token"`
}

Jump to

Keyboard shortcuts

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