docs icon indicating copy to clipboard operation
docs copied to clipboard

Compose: Add guidance for using host network in Swarm mode and Docker Stack

Open deahtstroke opened this issue 7 months ago • 2 comments

Description

This PR adds a new how-to section explaining how to use the host network when deploying services in Swarm mode via docker stack deploy.

Key additions:

  • YAML example showing how to reference the built-in host network as an external network.
  • A note outlining key limitations when using host networking with Swarm, such as:
    • Only supported in global service mode
    • No support for Swarm ingress networking or service discovery
    • Port-binding limitations

This is meant to clarify a niche but important case for users deploying Compose files to Swarm clusters that need access to the host's network. Let me know if there are other cross-references I should do in other parts of the docs.

Related issues or tickets

Issue 22684

Reviews

  • [ ] Technical review
  • [ ] Editorial review
  • [ ] Product review

deahtstroke avatar May 30 '25 03:05 deahtstroke

Deploy Preview for docsdocker ready!

Name Link
Latest commit 0d85e2abd40c220eadb83dbce025ec29dc0363b4
Latest deploy log https://app.netlify.com/projects/docsdocker/deploys/68392c034f64eb0008846aab
Deploy Preview https://deploy-preview-22724--docsdocker.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.

netlify[bot] avatar May 30 '25 03:05 netlify[bot]

Thanks for the PR @deahtstroke. Will take a look shortly

aevesdocker avatar May 30 '25 07:05 aevesdocker

Hi, any update on the review of this PR?

deahtstroke avatar Jul 01 '25 01:07 deahtstroke