diff options
Diffstat (limited to 'kubernetes/config/docker/init/src/config/robot/eteshare/config/vm_config2robot.sh')
-rwxr-xr-x | kubernetes/config/docker/init/src/config/robot/eteshare/config/vm_config2robot.sh | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/kubernetes/config/docker/init/src/config/robot/eteshare/config/vm_config2robot.sh b/kubernetes/config/docker/init/src/config/robot/eteshare/config/vm_config2robot.sh new file mode 100755 index 0000000000..962eea86ec --- /dev/null +++ b/kubernetes/config/docker/init/src/config/robot/eteshare/config/vm_config2robot.sh @@ -0,0 +1,19 @@ +#!/bin/bash + +# +# Make vm1_robot config available to robot +# +CONFIG=/opt/config +PROPERTIES=/opt/eteshare/config/vm_properties.py +GLOBAL_VM_PROPERTIES="# File generated from /opt/config\n#\n" +for f in `ls $CONFIG/*.txt`; +do + VALUE=`cat $f` + NAME=${f%.*} + NAME=${NAME##*/} + GLOBAL_VM_PROPERTIES=$"$GLOBAL_VM_PROPERTIES \"$NAME\" : \"$VALUE\",\n" +done +GLOBAL_VM_PROPERTIES=${GLOBAL_VM_PROPERTIES/%,\\n/\}} +echo -e $GLOBAL_VM_PROPERTIES > $PROPERTIES +REGION=`cat $CONFIG/region.txt` +echo -e "\nGLOBAL_OPENSTACK_SERVICE_REGION = \"$REGION\"" >> /opt/eteshare/config/integration_robot_properties.py |