hs-test: use anchors in yaml config files
Volumes can be referenced with anchors to reduce text duplication
and to explicitly show which containers share a volume.
Type: test
Signed-off-by: Maros Ondrejicka <maros.ondrejicka@pantheon.tech>
Change-Id: Id408a78262573b3faf2257c32bfa569eca2e2049
diff --git a/extras/hs-test/topo.go b/extras/hs-test/topo.go
index cf50dad..b7e883b 100644
--- a/extras/hs-test/topo.go
+++ b/extras/hs-test/topo.go
@@ -11,11 +11,12 @@
type NetDevConfig map[string]interface{}
type ContainerConfig map[string]interface{}
+type VolumeConfig map[string]interface{}
type YamlTopology struct {
Devices []NetDevConfig `yaml:"devices"`
Containers []ContainerConfig `yaml:"containers"`
- Volumes []string `yaml:"volumes"`
+ Volumes []VolumeConfig `yaml:"volumes"`
}
func AddAddress(device, address, ns string) error {