config

package
v0.0.0-...-3f9a457 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2020 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Releases []ConfigRelease `yaml:"releases"`
}

type ConfigRelease

type ConfigRelease struct {
	Crontab      string   `yaml:"crontab"`
	Project      *string  `yaml:"project"`
	Environments []string `yaml:"environments"`
	Trigger      string   `yaml:"trigger"`
	AutoApprove  bool     `yaml:"autoApprove"`

	ReleaseDefinitions struct {
		SearchText                   *string   `yaml:"searchText"`
		ArtifactType                 *string   `yaml:"artifactType"`
		ArtifactSourceId             *string   `yaml:"artifactSourceId"`
		Path                         *string   `yaml:"path"`
		IsExactNameMatch             *bool     `yaml:"isExactNameMatch"`
		TagFilter                    *[]string `yaml:"tagFilter"`
		DefinitionIdFilter           *[]string `yaml:"definitionIdFilter"`
		SearchTextContainsFolderName *bool     `yaml:"searchTextContainsFolderName"`
	} `yaml:"releaseDefinitions"`
}

type Opts

type Opts struct {
	// general settings
	DryRun     bool   `long:"dry-run"       env:"DRY_RUN"     description:"Dry run (no redeploy triggered)"`
	ConfigPath string `long:"config"        env:"CONFIG"      description:"Config file (yaml)" required:"true"`
	Singleshot bool   `long:"singleshot"    env:"SINGLESHOT"  description:"Trigger deployments and exit (ignoring cron)"`

	// logger
	Logger struct {
		Debug   bool `           long:"debug"        env:"DEBUG"    description:"debug mode"`
		Verbose bool `short:"v"  long:"verbose"      env:"VERBOSE"  description:"verbose mode"`
		LogJson bool `           long:"log.json"     env:"LOG_JSON" description:"Switch log output to json format"`
	}

	// azuredevops
	AzureDevops OptsAzureDevops

	// notification
	Notification OptsNotification

	// server settings
	ServerBind string `long:"bind" env:"SERVER_BIND"  description:"Server address"  default:":8080"`
}

type OptsAzureDevops

type OptsAzureDevops struct {
	OrganizationUrl string `` /* 174-byte string literal not displayed */
	AccessToken     string `long:"azuredevops.accesstoken"        env:"AZUREDEVOPS_ACCESSTOKEN"    description:"Personal access token"  required:"true"`
}

type OptsNotification

type OptsNotification struct {
	Template string   `long:"notification.template" env:"NOTIFICATION_TEMPLATE"  description:"Notification template" default:"%v"`
	Urls     []string `` /* 138-byte string literal not displayed */
}

Jump to

Keyboard shortcuts

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