Documentation
¶
Index ¶
Constants ¶
View Source
const ( StrategyManifestFile = "manifest_file" StrategyResolvedDigest = "resolved_image_digest" StrategyGitSHA = "git_sha" )
View Source
const ( PullNever = "never" PullAlways = "always" PullMissing = "missing" )
Pull policy values for DeployConfig.Pull. See ADR 0010.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BrokerConfig ¶
type BrokerConfig struct {
BaseURL string `yaml:"base_url"`
// contains filtered or unexported fields
}
BrokerConfig holds the broker endpoint. Credentials live in env vars only.
func (BrokerConfig) Password ¶
func (b BrokerConfig) Password() string
func (BrokerConfig) Token ¶
func (b BrokerConfig) Token() string
func (BrokerConfig) Username ¶
func (b BrokerConfig) Username() string
type ComposeConfig ¶
type ComposeConfig struct {
Files []string `yaml:"files"`
ProjectName string `yaml:"project_name"`
}
ComposeConfig selects which Compose files and project name c2quay drives.
type Config ¶
type Config struct {
Compose ComposeConfig `yaml:"compose"`
Broker BrokerConfig `yaml:"broker"`
Versioning VersioningConfig `yaml:"versioning"`
Deploy DeployConfig `yaml:"deploy"`
Environments map[string]Environment `yaml:"environments"`
// Path is the absolute path of the file this config was loaded from.
Path string `yaml:"-"`
}
Config is the top-level shape of c2quay.yml.
func (*Config) LookupEnvironment ¶
func (c *Config) LookupEnvironment(name string) (Environment, bool)
LookupEnvironment returns the environment config and true if present.
type DeployConfig ¶
type DeployConfig struct {
Wait bool `yaml:"wait"`
WaitTimeout time.Duration `yaml:"wait_timeout"`
// Pull controls whether c2quay runs `docker compose pull` between the
// gate and `compose up`. Values: "never" (default), "always", "missing".
// See ADR 0010.
Pull string `yaml:"pull"`
Smoke SmokeConfig `yaml:"smoke"`
}
DeployConfig tunes the deploy pipeline.
type Environment ¶
type Environment struct {
AllOrNothing bool `yaml:"all_or_nothing"`
Services map[string]ServiceMapping `yaml:"services"`
}
Environment maps logical services to pacticipants in the broker.
type ServiceMapping ¶
type ServiceMapping struct {
Pacticipant string `yaml:"pacticipant"`
}
ServiceMapping is a Compose-service → Pact-pacticipant link.
type SmokeConfig ¶
type SmokeConfig struct {
Command string `yaml:"command"`
Timeout time.Duration `yaml:"timeout"`
Env map[string]string `yaml:"env"`
}
SmokeConfig describes the optional post-deploy smoke script.
type VersioningConfig ¶
type VersioningConfig struct {
Strategy string `yaml:"strategy"`
Options map[string]string `yaml:"options"`
}
VersioningConfig picks one of the supported release-identity strategies.
Click to show internal directories.
Click to hide internal directories.