Help us shape the future of Go! Take the 2026 Go Developer Survey

docker

package
v0.83.0 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2026 License: Apache-2.0 Imports: 13 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InstallCompose added in v0.82.0

func InstallCompose(host *remoteComp.Host, opts ...pulumi.ResourceOption) (command.Command, error)

InstallCompose installs docker-compose on the host at provision time. Call this explicitly for cloud environments that do not use pre-baked AMIs (Azure, GCP). AWS e2e AMIs have docker-compose v2.27.0 pre-baked.

func InstallDocker added in v0.82.0

func InstallDocker(host *remoteComp.Host, opts ...pulumi.ResourceOption) (command.Command, error)

InstallDocker installs Docker on the host at provision time. Call this explicitly for cloud environments that do not use pre-baked AMIs (Azure, GCP). AWS e2e AMIs have Docker pre-baked.

func SetupECRDockerAuth added in v0.82.0

func SetupECRDockerAuth(n namer.Namer, host *remoteComp.Host, opts ...pulumi.ResourceOption) (command.Command, error)

SetupECRDockerAuth merges credsStore=ecr-login into ~/.docker/config.json (preserving existing keys). docker-credential-ecr-login and jq are expected to already be present on the host (pre-baked in AWS e2e AMIs); this enables automatic authentication against ECR registries (including pull-through caches).

TODO(ACIX-1305 follow-up): RHEL family has no -e2e AMI yet (introduced by the SBOM/RHEL10 work in #51486), so the helper binary and jq are still installed at runtime there. Migrated OSes assume both are pre-baked. Remove the RHEL-family install once a RHEL 10 -e2e AMI bakes them.

Types

type ComposeInlineManifest

type ComposeInlineManifest struct {
	Name    string
	Content pulumi.StringInput
}

type ComposeManifest

type ComposeManifest struct {
	Version  string                            `yaml:"version"`
	Services map[string]ComposeManifestService `yaml:"services"`
}

type ComposeManifestService

type ComposeManifestService struct {
	Pid           string         `yaml:"pid,omitempty"`
	Privileged    bool           `yaml:"privileged,omitempty"`
	Ports         []string       `yaml:"ports,omitempty"`
	Image         string         `yaml:"image"`
	ContainerName string         `yaml:"container_name"`
	Volumes       []string       `yaml:"volumes"`
	Environment   map[string]any `yaml:"environment"`
}

type Manager

type Manager struct {
	pulumi.ResourceState
	components.Component

	Host *remoteComp.Host `pulumi:"host"`
	// contains filtered or unexported fields
}

func NewAWSManager added in v0.79.0

func NewAWSManager(e config.Env, host *remoteComp.Host, opts ...pulumi.ResourceOption) (*Manager, error)

NewAWSManager creates a docker Manager and wires the host's Amazon ECR credentials helper so it authenticates automatically against ECR registries (including our pull-through cache). The helper itself is pre-baked into the AWS e2e AMI — NewAWSManager only writes ~/.docker/config.json via SetupECRDockerAuth. Use this instead of NewManager when the host is on AWS.

When ImagePullRegistry is configured, DD_REGISTRY is automatically injected into every ComposeStrUp call so that compose files using ${DD_REGISTRY:-docker.io} pull from the ECR pull-through cache for Docker Hub images. Callers may still override DD_REGISTRY by passing it explicitly in their envVars map.

func NewManager

func NewManager(e config.Env, host *remoteComp.Host, opts ...pulumi.ResourceOption) (*Manager, error)

func (*Manager) ComposeFileUp

func (d *Manager) ComposeFileUp(composeFilePath string, opts ...pulumi.ResourceOption) (command.Command, error)

func (*Manager) ComposeStrUp

func (d *Manager) ComposeStrUp(name string, composeManifests []ComposeInlineManifest, envVars pulumi.StringMap, opts ...pulumi.ResourceOption) (command.Command, error)

func (*Manager) Export

func (d *Manager) Export(ctx *pulumi.Context, out *ManagerOutput) error

type ManagerOutput

type ManagerOutput struct {
	components.JSONImporter

	Host remoteComp.HostOutput `json:"host"`
}

Jump to

Keyboard shortcuts

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