composebuilder

package
v0.26.3 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2017 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetDockerComposeProjectName

func GetDockerComposeProjectName(appDir string) string

GetDockerComposeProjectName creates a docker compose project name the same way docker-compose mutates the COMPOSE_PROJECT_NAME env var

func GetServiceDockerConfigs added in v0.26.0

func GetServiceDockerConfigs(appConfig types.AppConfig, serviceConfig types.ServiceConfig, serviceData types.ServiceData, role string, appDir string, homeDir string, mode BuildMode) (types.DockerConfigs, error)

GetServiceDockerConfigs returns the DockerConfigs for a service and its dependencies in docker-compose.yml

Types

type BuildMode added in v0.26.0

type BuildMode uint

BuildMode is what type of docker compose config should be created

const (
	// BuildModeLocalDevelopment used for `exo run` and `exo test` without flags
	BuildModeLocalDevelopment BuildMode = iota
	// BuildModeLocalDevelopmentNoMount used for `exo run` and `exo test` with no-mount flag
	BuildModeLocalDevelopmentNoMount
	// BuildModeLocalProduction used for `exo run` with production flag
	BuildModeLocalProduction
	// BuildModeDeployProduction used for `exo deploy`
	BuildModeDeployProduction
)

type DevelopmentDockerComposeBuilder added in v0.26.0

type DevelopmentDockerComposeBuilder struct {
	AppConfig                types.AppConfig
	ServiceConfig            types.ServiceConfig
	ServiceData              types.ServiceData
	Mode                     BuildMode
	BuiltAppDependencies     map[string]config.AppDevelopmentDependency
	BuiltServiceDependencies map[string]config.AppDevelopmentDependency
	Role                     string
	AppDir                   string
	HomeDir                  string
}

DevelopmentDockerComposeBuilder contains the docker-compose.yml config for a single service

func NewDevelopmentDockerComposeBuilder added in v0.26.0

func NewDevelopmentDockerComposeBuilder(appConfig types.AppConfig, serviceConfig types.ServiceConfig, serviceData types.ServiceData, role, appDir, homeDir string, mode BuildMode) *DevelopmentDockerComposeBuilder

NewDevelopmentDockerComposeBuilder is DevelopmentDockerComposeBuilder's constructor

type ProductionDockerComposeBuilder added in v0.26.0

type ProductionDockerComposeBuilder struct {
	ServiceData       types.ServiceData
	BuiltDependencies map[string]config.AppProductionDependency
	Role              string
	AppDir            string
}

ProductionDockerComposeBuilder contains the docker-compose.yml config for a single service

func NewProductionDockerComposeBuilder added in v0.26.0

func NewProductionDockerComposeBuilder(appConfig types.AppConfig, serviceConfig types.ServiceConfig, serviceData types.ServiceData, role, appDir string) *ProductionDockerComposeBuilder

NewProductionDockerComposeBuilder is ProductionDockerComposeBuilder's constructor

Jump to

Keyboard shortcuts

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