config

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2019 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitRepo

func InitRepo(dir string) *git2.Repository

func InitRepoWithCommit

func InitRepoWithCommit(dir string) (plumbing.Hash, *git2.Repository)

Types

type CIConfig

type CIConfig struct {
	Azure     *ci.Azure     `yaml:"azure"`
	Buildkite *ci.Buildkite `yaml:"buildkite"`
	Gitlab    *ci.Gitlab    `yaml:"gitlab"`
	Github    *ci.Github    `yaml:"github"`
	TeamCity  *ci.TeamCity  `yaml:"teamcity"`
}

type Config

type Config struct {
	VCS                 *VCSConfig       `yaml:"vcs"`
	CI                  *CIConfig        `yaml:"ci"`
	Registry            *RegistryConfig  `yaml:"registry"`
	Environments        []Environment    `yaml:"environments"`
	Scaffold            *scaffold.Config `yaml:"scaffold"`
	AvailableCI         []ci.CI
	AvailableRegistries []registry.Registry
}

func InitEmptyConfig

func InitEmptyConfig() *Config

func Load

func Load(dir string, out io.Writer) (*Config, error)

func (*Config) CurrentCI

func (c *Config) CurrentCI() ci.CI

func (*Config) CurrentEnvironment

func (c *Config) CurrentEnvironment(environment string) (*Environment, error)

func (*Config) CurrentRegistry

func (c *Config) CurrentRegistry() registry.Registry

func (*Config) CurrentVCS

func (c *Config) CurrentVCS() vcs.VCS

type Environment

type Environment struct {
	Name       string `yaml:"name"`
	Context    string `yaml:"context"`
	Namespace  string `yaml:"namespace"`
	Kubeconfig string `yaml:"kubeconfig"`
}

type RegistryConfig

type RegistryConfig struct {
	Dockerhub *registry.Dockerhub `yaml:"dockerhub"`
	ECR       *registry.ECR       `yaml:"ecr"`
	Github    *registry.Github    `yaml:"github"`
	Gitlab    *registry.Gitlab    `yaml:"gitlab"`
	Quay      *registry.Quay      `yaml:"quay"`
}

type VCSConfig

type VCSConfig struct {
	VCS vcs.VCS
}

Directories

Path Synopsis
ci
vcs
vcs/mocks
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

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