Skip to content

[17.06] Support --network=host and --network=bridge in stack deploy #131

@mavenugo

Description

@mavenugo

With 17.06, moby supports --network=host and --network=bridge in docker service create.
But when used in a stack file, it fails due to a strict check in the client.

$ cat host.yml
networks:
  host:
    external: true
services:
  test:
    image: mrjana/simpleweb:latest
    networks:
      host : null
    command: simpleweb
version: '3.0'
volumes: {}


$ docker stack deploy --compose-file=host.yml testh
network "host" is declared as external, but it is not in the right scope: "local" instead of "swarm"

I think we should relax this check and let the engine fail for any such invalid external network configuration.

cc @dnephin wdyt ?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions