docker

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DockerfileDev  string = "dev.Dockerfile"
	DockerfileProd string = "prod.Dockerfile"
)

Variables

This section is empty.

Functions

func CheckDrift

func CheckDrift(servicePath string, hotReload, usesDB bool) ([]string, error)

CheckDrift compares the dev/prod Dockerfiles under servicePath against what the current generator would emit for hotReload + usesDB and returns the paths of files whose contents disagree.

Missing Dockerfiles are not reported — a user who deleted them did so deliberately, and refresh isn't in the business of resurrecting them.

This is a read-only invariant check: drift can come from settings changing in project.toml after the service was scaffolded, or from the user hand-editing the Dockerfile. Refresh can't distinguish the two and must not overwrite either, so it surfaces the path and lets the human decide.

func Init

func Init(servicePath string, usesHotReload, usesDB bool) error

Types

type Compose

type Compose struct {
	Content string
}

type Dockerfile

type Dockerfile struct {
	// contains filtered or unexported fields
}

Dockerfile builds the dev and prod Dockerfiles for a service. The images never contain the Doppler CLI: secrets reach the container as plain environment variables, injected by docker-compose via env_file from .secrets/<env>_<service>.env on the host.

func NewDockerFile

func NewDockerFile(hotReload, usesDB bool) Dockerfile

func (Dockerfile) Construct

func (df Dockerfile) Construct(serviceName, dockerAirFile, path string) error

Construct writes the development and production Dockerfiles into path.

type Ignore

type Ignore struct {
	Content string
}

func NewDefaultIgnore

func NewDefaultIgnore() Ignore

func (Ignore) Write

func (i Ignore) Write(servicePath string) error

Jump to

Keyboard shortcuts

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