orchestrator

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2025 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Down

func Down(ctx context.Context, projectDirectory string) error

Down orchestrates the 'reactor down' logic for a single service.

func Up

func Up(ctx context.Context, upConfig UpConfig) (*config.ResolvedConfig, string, error)

Up orchestrates the entire 'reactor up' logic for a single service. It returns the final resolved config and container ID on success.

Types

type PortMapping

type PortMapping struct {
	HostPort      int
	ContainerPort int
}

PortMapping represents a port forwarding configuration

type UpConfig

type UpConfig struct {
	// The absolute path to the service's project directory (the one containing .devcontainer).
	ProjectDirectory string

	// An optional account override from the workspace file. If empty, the account
	// from the devcontainer.json file will be used.
	AccountOverride string

	// A flag to force a rebuild of the container image.
	ForceRebuild bool

	// An optional map of labels to apply to the container (for workspace tracking).
	Labels map[string]string

	// An optional name prefix for the container (e.g., "reactor-ws-api-").
	NamePrefix string

	// CLI-provided port mappings that override devcontainer.json ports
	CLIPortMappings []string

	// Enable discovery mode (no mounts)
	DiscoveryMode bool

	// Enable Docker host integration (dangerous)
	DockerHostIntegration bool

	// Enable verbose output
	Verbose bool
}

UpConfig contains all necessary, pre-resolved parameters for an 'up' operation.

Jump to

Keyboard shortcuts

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