Use networking for version 2 Compose files

- Remove --x-networking and --x-network-driver
- There's now no way to set a network driver - this will be added back
  with the 'networks' key

Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
This commit is contained in:
Aanand Prasad 2016-01-12 16:26:20 +00:00
commit a027a0079c
9 changed files with 49 additions and 36 deletions

View file

@ -48,11 +48,12 @@ class Project(object):
]
@classmethod
def from_config(cls, name, config_data, client, use_networking=False, network_driver=None):
def from_config(cls, name, config_data, client):
"""
Construct a Project from a config.Config object.
"""
project = cls(name, [], client, use_networking=use_networking, network_driver=network_driver)
use_networking = (config_data.version and config_data.version >= 2)
project = cls(name, [], client, use_networking=use_networking)
if use_networking:
remove_links(config_data.services)