|
|
|
@ -94,7 +94,7 @@ def test_create(loop, project, manager):
|
|
|
|
|
"CapAdd": ["ALL"],
|
|
|
|
|
"Binds": [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
],
|
|
|
|
|
"Privileged": True
|
|
|
|
|
},
|
|
|
|
@ -132,7 +132,7 @@ def test_create_with_tag(loop, project, manager):
|
|
|
|
|
"CapAdd": ["ALL"],
|
|
|
|
|
"Binds": [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
],
|
|
|
|
|
"Privileged": True
|
|
|
|
|
},
|
|
|
|
@ -173,7 +173,7 @@ def test_create_vnc(loop, project, manager):
|
|
|
|
|
"CapAdd": ["ALL"],
|
|
|
|
|
"Binds": [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network")),
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network")),
|
|
|
|
|
'/tmp/.X11-unix/:/tmp/.X11-unix/'
|
|
|
|
|
],
|
|
|
|
|
"Privileged": True
|
|
|
|
@ -216,7 +216,7 @@ def test_create_start_cmd(loop, project, manager):
|
|
|
|
|
"CapAdd": ["ALL"],
|
|
|
|
|
"Binds": [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
],
|
|
|
|
|
"Privileged": True
|
|
|
|
|
},
|
|
|
|
@ -255,7 +255,7 @@ def test_create_environment(loop, project, manager):
|
|
|
|
|
"CapAdd": ["ALL"],
|
|
|
|
|
"Binds": [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
],
|
|
|
|
|
"Privileged": True
|
|
|
|
|
},
|
|
|
|
@ -310,7 +310,7 @@ def test_create_image_not_available(loop, project, manager):
|
|
|
|
|
"CapAdd": ["ALL"],
|
|
|
|
|
"Binds": [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
],
|
|
|
|
|
"Privileged": True
|
|
|
|
|
},
|
|
|
|
@ -530,7 +530,7 @@ def test_update(loop, vm):
|
|
|
|
|
"CapAdd": ["ALL"],
|
|
|
|
|
"Binds": [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
],
|
|
|
|
|
"Privileged": True
|
|
|
|
|
},
|
|
|
|
@ -598,7 +598,7 @@ def test_update_running(loop, vm):
|
|
|
|
|
"CapAdd": ["ALL"],
|
|
|
|
|
"Binds": [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network"))
|
|
|
|
|
],
|
|
|
|
|
"Privileged": True
|
|
|
|
|
},
|
|
|
|
@ -875,8 +875,8 @@ def test_mount_binds(vm, tmpdir):
|
|
|
|
|
dst = os.path.join(vm.working_dir, "test/experimental")
|
|
|
|
|
assert vm._mount_binds(image_infos) == [
|
|
|
|
|
"{}:/gns3:ro".format(get_resource("modules/docker/resources")),
|
|
|
|
|
"{}:/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network")),
|
|
|
|
|
"{}:{}".format(dst, "/test/experimental")
|
|
|
|
|
"{}:/gns3volumes/etc/network:rw".format(os.path.join(vm.working_dir, "etc", "network")),
|
|
|
|
|
"{}:/gns3volumes{}".format(dst, "/test/experimental")
|
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
assert vm._volumes == ["/etc/network", "/test/experimental"]
|
|
|
|
|