NAME
Developer::Dashboard::Guide::Docker - Docker Compose workflows
DESCRIPTION
The Docker Compose workflows: the dashboard Compose commands, the service toggles and the development overlays.
This guide is part of the Developer::Dashboard manual. The main page is the front door for the whole set.

The base stack, the development overlay and the disabled markers combine into the services that run.
Docker Compose
Show the Docker command reference without starting or inspecting containers:
d2 docker --help
Both d2 docker --help and d2 docker --help print the available Compose and service-management commands. The shell completion list includes compose, list, enable, disable, and development; after docker development, completion offers enable and disable.
Inspect the resolved compose stack without running Docker:
d2 docker compose --dry-run config
Include addons or modes:
d2 docker compose --addon mailhog --mode dev up -d
d2 docker compose config green
d2 docker compose config
d2 docker list
d2 docker list --disabled
d2 docker list --enabled
d2 docker disable green
d2 docker enable green
d2 docker development enable green
d2 docker development disable green
The resolver also supports isolated service folders without adding entries to dashboard JSON config. If ./.developer-dashboard/config/docker/green/compose.yml exists in the current project it wins; otherwise the resolver falls back to ~/.developer-dashboard/config/docker/green/compose.yml. d2 docker compose config and operational commands first resolve the base Compose config, including configured non-service project/addon/mode files, and read its resulting services: map.
Only those service names are used to discover isolated service folders; a service name appearing only in the CLI arguments or in an unrelated runtime folder cannot introduce an overlay. The base config resolution is a real docker compose config call, not a raw YAML parse, so Compose's own includes, interpolation, and merge rules determine the authoritative list. The selected per-service files are then layered and materialised before the requested operation runs.
Service names emitted by Compose must be non-empty single path segments; names containing separators or directory-navigation segments are rejected before runtime folders are searched. If any matching config/docker/<service> directory in the active runtime layers contains disabled.yml, the service is skipped. Each enabled isolated folder contributes compose.yml as its base whenever it exists.
Its optional development.compose.yml is layered after the base only when develop.yml exists in any matching service folder across those layers; without a marker, the development file is ignored even when present.
If the marker exists but the development file does not, only the base is loaded and no error is raised. Toggle development mode without creating or deleting the file manually with d2 docker development enable <service> or d2 docker development disable <service>.
A newly enabled marker is written under the selected home runtime: ~/.developer-dashboard when it exists (or when neither runtime name exists), otherwise ~/.d2. Disabling development removes every develop.yml marker for that service across active layers.
To toggle the disabled marker without creating or deleting the file manually, use d2 docker disable <service> or d2 docker enable <service>. The disable toggle uses the same selected home runtime root.
d2 docker enable <service> removes every disabled.yml marker for that service across active layers. To inspect the effective marker state without walking the folders manually, use d2 docker list.
Add --disabled to show only disabled services or --enabled to show only enabled services.
If the invocation directory contains compose.yml, compose.yaml, docker-compose.yml, or docker-compose.yaml, those local files are the base stack and the Compose command runs from that directory. For execution, the first docker compose config runs against the base and other configured non-service layers.
Its resolved services—not service names guessed from command arguments—control isolated-service lookup across home, project, and nested skill runtime roots. The selected service files are added only after that first config succeeds; disabled folders are excluded and development files require a matching develop.yml marker.
In a dry run, Docker is not invoked, so the resolver reports a source-based preview instead of a Compose-resolved service list. This distinction keeps dry-run non-executing while ensuring real operations follow Compose's own effective service map. If no local base or explicit Compose file exists but isolated runtime service files do, the enabled files seed the first config pass to preserve ecosystem-wide auto-discovery; Compose's resulting service map still controls the final stack.
For operational actions such as build, up, and down, layered files are first materialised into a temporary Compose file. The final Compose invocation also receives the original project directory explicitly, so relative build and volume paths and the default project identity continue to come from the local Compose project rather than the temporary file's directory.
An explicit --project-directory supplied by the user is preserved. An undefined Compose argument or an empty/missing project-directory value is rejected before the Compose executable is called.
The public helper routes these actions through the materialising runner (not directly through the unresolved -f list), keeps the temporary merged file until the operation exits, and streams Compose stdout and stderr normally. This applies to build, up, down, and other Compose operations; config remains available for inspection without starting containers.
Before saving that merged output, the resolver preserves valid UTF-8 sequences and converts isolated non-UTF-8 Windows-1252 bytes from the combined inputs to UTF-8. The temporary file is written as raw bytes only after normalisation, so the same clean merged YAML is used by config, up, down, build, ps, logs, and other Compose operations. Undefined Windows-1252 octets become the Unicode replacement character rather than being written as invalid UTF-8.
This materialisation also runs when the dashboard resolver found no explicit layered files. In that case Docker Compose discovers its ordinary base file from the configured Compose working directory, emits the effective config, and the requested operation consumes the generated temporary file. This keeps the UTF-8 normalisation and common execution path consistent for build, ps, and other verbs even when no runtime overlay was selected.
During compose execution the dashboard exports DDDC as the runtime config/docker directory for the current runtime, so compose YAML can keep using ${DDDC} paths inside the YAML itself. Project-local isolated services are discovered from that same ./.developer-dashboard/config/docker/<service>/... tree.
Wrapper flags such as --service, --addon, --mode, --project, and --dry-run are consumed first, and all remaining docker compose flags such as -d and --build pass straight through to the real docker compose command.
If one resolved service comes from an installed skill docker root, the resolver also loads that skill's <skill-root>/.env file into the compose environment before docker-config, addon, and mode env overlays are applied. Only skills whose compose service files actually participate are included, disabled skills are skipped, and <skill-root>/.env.pl is not executed from this compose path.
Nested skill services expand their env chain from the root nested skill to the participating leaf service, preserving overwritten parent keys under cumulative aliases such as foo_VERSION and foo_bar_VERSION before the leaf value becomes the plain key. The resolver also exports one skill-specific <skill-name>_DDDC variable for each participating skill, using the leaf skill name with non-identifier characters normalised to underscores and pointing that variable at the owning config/docker/ root.
Nested skill services additionally export the full cumulative skill path alias such as foo_bar_zzz_DDDC for the same compose root, while the leaf alias stays available as zzz_DDDC.
When one or more Compose services are explicitly selected, skill env files are resolved only for those selected services during interpolation; unrelated skill service folders cannot replace a selected service's same-named env key merely because they are enumerated later. If no selected service is present in the effective base config, or the operation selects no service, env files for all effective base services are used.
This keeps sequential commands such as d2 docker compose up foo and d2 docker compose up bar scoped to the matching skill env while preserving all-service operations. When --dry-run is omitted, the dashboard hands off with exec so the terminal sees the normal streaming output from docker compose itself instead of a dashboard JSON wrapper.
Publishing Docker Hub images
The repository's master-push workflow publishes a runnable Docker image from the latest master checkout. It first runs the repository install.sh to install the platform tools and Perl environment, then builds a fresh Dist::Zilla archive from that checked-out source and installs that archive into the image with cpanm --notest.
This final local-archive install deliberately replaces the version that the bootstrap installer may have fetched from MetaCPAN, so the image contains the current repository code.
The regular container/release gates run the full test and coverage suites before publishing. The multi-platform image build skips rerunning those suites under QEMU for each target architecture; the tarball itself is still installed and its install is verified separately in a blank Docker environment.
The workflow selects the GitHub Actions environment release, whose secrets DOCKER_HUB_USER and DOCKER_HUB_TOKEN provide the Docker Hub credentials. It pushes two tags under DOCKER_HUB_USER/developer-dashboard: the distribution version read from dist.ini (for example 5.88) and latest.
A manual workflow dispatch also builds the current master branch. The image targets linux/amd64 and linux/arm64; Docker does not support a macOS-kernel image platform, while Apple Silicon can run the Linux arm64 image using Docker Desktop's Linux VM.
The Ubuntu Linux base image is pinned by its multi-platform manifest digest, and every GitHub Action dependency is pinned to a full commit SHA.
For example, pull the moving tag or a pinned version:
docker pull YOUR_DOCKER_HUB_USER/developer-dashboard:latest
docker pull YOUR_DOCKER_HUB_USER/developer-dashboard:5.88
The container entrypoint is d2. The versioned tag is intended for selecting a known image build; latest follows successful master builds.

d2 docker list shows every service folder the resolver found, and whether each one is enabled.