rc

package
Version: v3.10.0-rc.5+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2018 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNoTargetSpecified = errors.New("no target specified")
	ErrNoTargetFromURL   = errors.New("no target matching url")
)

Functions

func DeleteTarget

func DeleteTarget(targetName TargetName) error

func LoadTargetFromURL

func LoadTargetFromURL(url, team string, tracing bool) (Target, TargetName, error)

func LoadTargets

func LoadTargets() (*targetDetailsYAML, error)

func SaveTarget

func SaveTarget(
	targetName TargetName,
	api string,
	insecure bool,
	teamName string,
	token *TargetToken,
	caCert string,
) error

Types

type ErrVersionMismatch

type ErrVersionMismatch struct {
	// contains filtered or unexported fields
}

func NewErrVersionMismatch

func NewErrVersionMismatch(flyVersion string, atcVersion string, targetName TargetName) ErrVersionMismatch

func (ErrVersionMismatch) Error

func (e ErrVersionMismatch) Error() string

type Target

type Target interface {
	Client() concourse.Client
	Team() concourse.Team
	CACert() string
	Validate() error
	ValidateWithWarningOnly() error
	TLSConfig() *tls.Config
	URL() string
	WorkerVersion() (string, error)
	IsWorkerVersionCompatible(string) (bool, error)
	Token() *TargetToken
	TokenAuthorization() (string, bool)
}

func LoadTarget

func LoadTarget(selectedTarget TargetName, tracing bool) (Target, error)

func LoadTargetWithInsecure

func LoadTargetWithInsecure(
	selectedTarget TargetName,
	teamName string,
	commandInsecure bool,
	caCert string,
	tracing bool,
) (Target, error)

func NewBasicAuthTarget

func NewBasicAuthTarget(
	name TargetName,
	url string,
	teamName string,
	insecure bool,
	username string,
	password string,
	caCert string,
	tracing bool,
) (Target, error)

func NewNoAuthTarget

func NewNoAuthTarget(
	name TargetName,
	url string,
	teamName string,
	insecure bool,
	caCert string,
	tracing bool,
) (Target, error)

func NewUnauthenticatedTarget

func NewUnauthenticatedTarget(
	name TargetName,
	url string,
	teamName string,
	insecure bool,
	caCert string,
	tracing bool,
) (Target, error)

type TargetName

type TargetName string

func (*TargetName) Complete

func (name *TargetName) Complete(match string) []flags.Completion

func (*TargetName) UnmarshalFlag

func (name *TargetName) UnmarshalFlag(value string) error

type TargetProps

type TargetProps struct {
	API      string       `yaml:"api"`
	TeamName string       `yaml:"team"`
	Insecure bool         `yaml:"insecure,omitempty"`
	Token    *TargetToken `yaml:"token,omitempty"`
	CACert   string       `yaml:"ca_cert,omitempty"`
}

type TargetToken

type TargetToken struct {
	Type  string `yaml:"type"`
	Value string `yaml:"value"`
}

type UnknownTargetError

type UnknownTargetError struct {
	TargetName TargetName
}

func (UnknownTargetError) Error

func (err UnknownTargetError) Error() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL