run

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2017 License: MIT Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DockerNetwork = "wedeploy"

DockerNetwork is the ID of the docker network

View Source
var WeDeployImage = "wedeploy/local:" + defaults.WeDeployImageTag

WeDeployImage is the docker image for the WeDeploy infrastructure

Functions

func GetWeDeployHost

func GetWeDeployHost() (string, error)

GetWeDeployHost gets the WeDeploy infrastructure host This is a temporary solution and it is NOT reliable

func MaybeStartDocker

func MaybeStartDocker()

MaybeStartDocker tries to run Docker on the system, if not started

func Run

func Run(ctx context.Context, flags Flags) (terminated bool, err error)

Run runs the WeDeploy infrastructure

func Stop

func Stop() error

Stop stops the WeDeploy infrastructure

func StopOutdatedImage

func StopOutdatedImage(nextImage string) error

StopOutdatedImage stops the WeDeploy infrastructure if outdated

func TryStartDocker

func TryStartDocker()

TryStartDocker tries to run Docker on the system

Types

type DockerMachine

type DockerMachine struct {
	Service string
	Image   string
	Flags   Flags

	Context context.Context
	// contains filtered or unexported fields
}

DockerMachine for the run command

func (*DockerMachine) IsTerminate

func (dm *DockerMachine) IsTerminate() bool

IsTerminate tells if the DockerMachine was terminated correctly (if Run was already run)

func (*DockerMachine) LoadDockerInfo

func (dm *DockerMachine) LoadDockerInfo() error

LoadDockerInfo loads the docker info on the DockerMachine object

func (*DockerMachine) Run

func (dm *DockerMachine) Run() (err error)

Run executes the WeDeploy infrastruture

func (*DockerMachine) Stop

func (dm *DockerMachine) Stop() error

Stop stops the machine

type Flags

type Flags struct {
	Debug  bool
	DryRun bool
}

Flags modifiers

type TCPPort

type TCPPort struct {
	Internal int
	Expose   int
}

TCPPort is used to control the exposed ports

Jump to

Keyboard shortcuts

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