cmd

package
v0.0.0-...-47d1103 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2015 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const (
	GeneratedByNamespace = "openshift.io/generated-by"
	GeneratedByNewApp    = "OpenShiftNewApp"
	GeneratedByNewBuild  = "OpenShiftNewBuild"
)

Variables

View Source
var ErrNoInputs = fmt.Errorf("no inputs provided")

ErrNoInputs is returned when no inputs are specified

Functions

This section is empty.

Types

type AppConfig

type AppConfig struct {
	SourceRepositories util.StringList
	ContextDir         string

	Components    util.StringList
	ImageStreams  util.StringList
	DockerImages  util.StringList
	Templates     util.StringList
	TemplateFiles util.StringList

	TemplateParameters util.StringList
	Groups             util.StringList
	Environment        util.StringList
	Labels             map[string]string

	AddEnvironmentToBuild bool

	Dockerfile string

	Name               string
	Strategy           string
	InsecureRegistry   bool
	OutputDocker       bool
	AllowMissingImages bool

	AsSearch bool
	AsList   bool

	Out    io.Writer
	ErrOut io.Writer
	// contains filtered or unexported fields
}

AppConfig contains all the necessary configuration for an application

func NewAppConfig

func NewAppConfig(typer runtime.ObjectTyper, mapper meta.RESTMapper, clientMapper resource.ClientMapper) *AppConfig

NewAppConfig returns a new AppConfig

func (*AppConfig) AddArguments

func (c *AppConfig) AddArguments(args []string) []string

AddArguments converts command line arguments into the appropriate bucket based on what they look like

func (*AppConfig) GetBuildEnvironment

func (c *AppConfig) GetBuildEnvironment(environment app.Environment) app.Environment

func (*AppConfig) HasArguments

func (c *AppConfig) HasArguments() bool

func (*AppConfig) Querying

func (c *AppConfig) Querying() bool

func (*AppConfig) RunAll

func (c *AppConfig) RunAll() (*AppResult, error)

RunAll executes the provided config to generate all objects.

func (*AppConfig) RunBuilds

func (c *AppConfig) RunBuilds() (*AppResult, error)

RunBuilds executes the provided config to generate just builds.

func (*AppConfig) RunQuery

func (c *AppConfig) RunQuery() (*QueryResult, error)

RunQuery executes the provided config and returns the result of the resolution.

func (*AppConfig) SetDockerClient

func (c *AppConfig) SetDockerClient(dockerclient *docker.Client)

SetDockerClient sets the passed Docker client in the application configuration

func (*AppConfig) SetOpenShiftClient

func (c *AppConfig) SetOpenShiftClient(osclient client.Interface, originNamespace string)

SetOpenShiftClient sets the passed OpenShift client in the application configuration

type AppResult

type AppResult struct {
	List *kapi.List

	Name       string
	BuildNames []string
	HasSource  bool
	Namespace  string
}

AppResult contains the results of an application

type QueryResult

type QueryResult struct {
	Matches app.ComponentMatches
	List    *kapi.List
}

QueryResult contains the results of a query (search or list)

type UsageError

type UsageError interface {
	UsageError(commandName string) string
}

UsageError is an interface for printing usage errors

Jump to

Keyboard shortcuts

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