Skip to content

fix: support relative bind mounts from agent containers#233

Closed
alex289 wants to merge 1 commit into
mainfrom
codex/host-deployments-dir
Closed

fix: support relative bind mounts from agent containers#233
alex289 wants to merge 1 commit into
mainfrom
codex/host-deployments-dir

Conversation

@alex289

@alex289 alex289 commented Jul 13, 2026

Copy link
Copy Markdown
Member

Summary

  • add optional HOST_DEPLOYMENTS_DIR configuration for host-visible deployment paths
  • translate deployment-local bind mount sources before deploys and image-update redeploys
  • keep bind-mount restrictions aligned with the translated host path
  • document the setting in the production and development Compose examples

Root cause

Compose resolves relative bind mount sources inside the OrcaCD agent container, for example to /deployments/<app>/data. The Docker daemon runs on the host and interprets bind sources in the host filesystem, so that container-internal path is not valid there.

Impact

Applications can use convenient relative mounts such as ./data:/app/data while their files remain directly accessible on the host below the configured deployment directory.

Validation

  • go test -race ./internal/agent -count=1
  • go test -race ./internal/agent/docker -run 'TranslateBindMountSources|Deploy_(TranslatesBindMountForAllowlistedApplication|RestrictMountsAllowsTranslatedDeploymentBind)|CheckAndPullImages_TranslatesBindMountBeforeUp' -count=1
  • go test ./... -run '^$'
  • git diff HEAD^ HEAD --check

The full Docker-daemon-backed test suite was not rerun during publishing; the focused regression tests and repository-wide Go compilation pass.

Possibly fixes #231

@alex289 alex289 marked this pull request as ready for review July 13, 2026 20:01
@codecov

codecov Bot commented Jul 13, 2026

Copy link
Copy Markdown

@alex289 alex289 marked this pull request as draft July 14, 2026 07:06
@alex289 alex289 closed this Jul 14, 2026
@alex289 alex289 deleted the codex/host-deployments-dir branch July 14, 2026 08:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: Absolute path required for volumes

1 participant