Refactor install_docker_compose function

Usually this function is followed by a run command, this change
ensure that docker-compose program is installed before its execution

Change-Id: Ic68616a1db1e3c5bee516985c74f369a956d6775
Signed-off-by: Victor Morales <victor.morales@intel.com>
Issue-ID: INT-436
diff --git a/bootstrap/vagrant-onap/lib/_onap_functions b/bootstrap/vagrant-onap/lib/_onap_functions
index f68d6db..c65e589 100755
--- a/bootstrap/vagrant-onap/lib/_onap_functions
+++ b/bootstrap/vagrant-onap/lib/_onap_functions
@@ -2,14 +2,18 @@
 
 # create_configuration_files() -  Store credentials in files
 function create_configuration_files {
-    mkdir -p /opt/config
-    echo $nexus_docker_repo > /opt/config/nexus_docker_repo.txt
-    echo $nexus_username > /opt/config/nexus_username.txt
-    echo $nexus_password > /opt/config/nexus_password.txt
-    echo $openstack_username > /opt/config/openstack_username.txt
-    echo $openstack_tenant_id > /opt/config/tenant_id.txt
-    echo $dmaap_topic > /opt/config/dmaap_topic.txt
-    echo $docker_version > /opt/config/docker_version.txt
+    local onap_config_folder="/opt/config"
+
+    mkdir -p $onap_config_folder
+    pushd $onap_config_folder
+    echo $nexus_docker_repo > nexus_docker_repo.txt
+    echo $nexus_username > nexus_username.txt
+    echo $nexus_password > nexus_password.txt
+    echo $openstack_username > openstack_username.txt
+    echo $openstack_tenant_id > tenant_id.txt
+    echo $dmaap_topic > dmaap_topic.txt
+    echo $docker_version > docker_version.txt
+    popd
 }
 
 # docker_openecomp_login() - Login to OpenECOMP Docker Hub