Pick the first container
Rather than inefficiently looping through all the containers that a service has and overriding each volumes_from value, pick the first one and return that. Signed-off-by: Mazz Mosley <mazz@houseofmnowster.com>
This commit is contained in:
parent
0ff84a78c6
commit
f9028703f4
3 changed files with 6 additions and 5 deletions
|
|
@ -211,7 +211,7 @@ class ProjectTest(unittest.TestCase):
|
|||
'volumes_from': ['vol']
|
||||
}
|
||||
], None)
|
||||
self.assertEqual(project.get_service('test')._get_volumes_from(), [cid + ':rw' for cid in container_ids])
|
||||
self.assertEqual(project.get_service('test')._get_volumes_from(), [container_ids[0] + ':rw'])
|
||||
|
||||
def test_net_unset(self):
|
||||
project = Project.from_dicts('test', [
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue