Documentation ¶
Index ¶
- Variables
- func CommandForDeploy(p *Project, deployEnv string) (command *exec.Cmd)
- func CommandsForGoBuilder(p *Project) (commands []*exec.Cmd)
- func CommandsForImageBuilder(p *Project, push bool) (commands []*exec.Cmd)
- func LoadEnv(envName string, feature string)
- func SetEnv(k string, v string)
- func WrapEnv(s string) string
- type Project
- func (p *Project) Command(args ...string) *exec.Cmd
- func (p *Project) Execute(args ...string)
- func (p *Project) Run(commands ...*exec.Cmd)
- func (p *Project) SetEnviron()
- func (p *Project) UnmarshalFromFile() error
- func (p Project) WithDesc(desc string) Project
- func (p Project) WithFeature(f string) Project
- func (p Project) WithGroup(group string) Project
- func (p Project) WithLanguage(pl string) Project
- func (p Project) WithName(name string) Project
- func (p Project) WithScripts(key string, scripts ...string) Project
- func (p Project) WithVersion(s string) Project
- func (p *Project) WriteToFile()
- type Script
- type Version
- func (v Version) IncreaseMajor() Version
- func (v Version) IncreaseMinor() Version
- func (v Version) IncreasePatch() Version
- func (v Version) IsStable() bool
- func (v Version) MarshalYAML() (interface{}, error)
- func (v Version) String() string
- func (v *Version) UnmarshalYAML(unmarshal func(interface{}) error) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( EnvVarRef = "PROJECT_REF" EnvVarBuildRef = "CI_COMMIT_SHA" EnvVarBuildBranch = "CI_COMMIT_REF" EnvVarRancherEnv = "RANCHER_ENVIRONMENT" EnvVarRancherUrl = "RANCHER_URL" EnvVarRancherAccessKey = "RANCHER_ACCESS_KEY" EnvVarRancherSecretKey = "RANCHER_SECRET_KEY" )
View Source
var ( EnvValRancherUrl = "http://rancher.profzone.net:38080" EnvValRancherAccessKey = "744E0D8EF311C269FED1" EnvValRancherSecretKey = "yBXzp7jdaaRqCtL92TJSRbekxzYr8x7Xr2r5rq11" )
View Source
var ( CIWorkingDirectory = "/drone/workspace" CIGolangRootPath = "/go/src" COGolangPackageName = "github.com/johnnyeven" )
View Source
var ( DOCKER_REGISTRY_KEY = "PROFZONE_DOCKER_REGISTRY" DOCKER_REGISTRY = "registry.profzone.net:5000" )
View Source
var DockerfileYmlOrders = []string{
"dockerfile.default.yml",
"dockerfile.yml",
}
View Source
var ProjectFile = "profzone.yml"
View Source
var VersionRegexp = regexp.MustCompile("(\\d+)\\.(\\d+)\\.(\\d+)")
Functions ¶
func CommandsForGoBuilder ¶
func CommandsForImageBuilder ¶
Types ¶
type Project ¶
type Project struct { Name string `env:"name" yaml:"name"` Group string `env:"group" yaml:"group,omitempty"` Version Version `env:"version" yaml:"version"` Desc string `env:"description" yaml:"description"` ProgramLanguage string `env:"program_language" yaml:"program_language"` Scripts map[string]Script `yaml:"scripts,omitempty"` Feature string `yaml:"feature,omitempty"` }
func (*Project) SetEnviron ¶
func (p *Project) SetEnviron()
func (*Project) UnmarshalFromFile ¶
func (Project) WithFeature ¶
func (Project) WithLanguage ¶
func (Project) WithVersion ¶
func (*Project) WriteToFile ¶
func (p *Project) WriteToFile()
type Version ¶
func FromVersionString ¶
func (Version) IncreaseMajor ¶
func (Version) IncreaseMinor ¶
func (Version) IncreasePatch ¶
func (Version) MarshalYAML ¶
func (*Version) UnmarshalYAML ¶
Click to show internal directories.
Click to hide internal directories.