Skip to content

Simplify Docker Compose naming to v2-only format - #1238

Merged
cristianrgreco merged 1 commit into
mainfrom
codex/compose-v2-name-simplification
Feb 17, 2026
Merged

Simplify Docker Compose naming to v2-only format#1238
cristianrgreco merged 1 commit into
mainfrom
codex/compose-v2-name-simplification

Conversation

@cristianrgreco

Copy link
Copy Markdown
Collaborator

Summary

  • Remove Compose v1-style project-prefix parsing and keep Compose v2 naming plus explicit container_name support.
  • Simplify compose docs to document only the current <service-name>-<index> naming format.
  • Rename compose fixture services from numeric names to service-a and service-b for clarity.
  • Inline literal Compose v2 container names in compose tests and remove the unused composeContainerName helper.

Verification

  • npm run format
  • npm run lint
  • npm test -- packages/testcontainers/src/container-runtime/clients/compose/parse-compose-container-name.test.ts packages/testcontainers/src/docker-compose-environment/docker-compose-environment.test.ts

Test Results

  • 27 tests passed across 2 test files.

Semver Impact

  • patch
  • The change is not breaking: public APIs are unchanged and only unsupported Compose v1 naming compatibility code was removed.

Closes #840

@netlify

netlify Bot commented Feb 17, 2026

Copy link
Copy Markdown

Deploy Preview for testcontainers-node ready!

Name Link
🔨 Latest commit ae294fe
🔍 Latest deploy log https://app.netlify.com/projects/testcontainers-node/deploys/699494cdde2c5c0008370e87
😎 Deploy Preview https://deploy-preview-1238--testcontainers-node.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.