WIP test configuration
diff --git a/xos/configurations/common/Makefile.cloudlab b/xos/configurations/common/Makefile.cloudlab
index 86b98e2..77fdb03 100644
--- a/xos/configurations/common/Makefile.cloudlab
+++ b/xos/configurations/common/Makefile.cloudlab
@@ -1,4 +1,7 @@
-all: flat_name nodes_yaml
+all: admin-openrc flat_name nodes_yaml
+
+admin-openrc:
+ sudo cat /root/setup/admin-openrc.sh > admin-openrc.sh
flat_name:
sudo bash -c "source /root/setup/admin-openrc.sh ; neutron net-list" |grep flat|awk '{print $$4}' > flat_net_name
diff --git a/xos/configurations/test/Dockerfile.test b/xos/configurations/test/Dockerfile.test
index 2f81553..43dbf67 100644
--- a/xos/configurations/test/Dockerfile.test
+++ b/xos/configurations/test/Dockerfile.test
@@ -1,5 +1,8 @@
-ADD /root/setup/admin-openrc.sh /root/setup/
-ADD .,/common/flat_net_name /root/setup/
-ADD ../common/cloudlab-nods.yaml /opt/xos/configurations/commmon/
+RUN mkdir -p /root/setup
+ADD xos/configurations/common/admin-openrc.sh /root/setup/
+ADD xos/configurations/common/flat_net_name /root/setup/
+ADD xos/configurations/common/cloudlab-nodes.yaml /opt/xos/configurations/commmon/
+
+#CMD ["/usr/bin/make -C /opt/xos/configurations/test -f Makefile.inside"]
CMD ["/bin/bash"]
diff --git a/xos/configurations/test/Makefile b/xos/configurations/test/Makefile
index 1e203a2..b1cca93 100644
--- a/xos/configurations/test/Makefile
+++ b/xos/configurations/test/Makefile
@@ -1,9 +1,10 @@
-MYIP=`hostname -i`
+MYIP:=$(shell hostname -i)
test: common_cloudlab
cat ../common/Dockerfile.common Dockerfile.test > Dockerfile
cd ../../..; sudo docker build -t xos -f xos/configurations/test/Dockerfile .
- sudo docker run -d --add-host="ctl:$(MYIP)" -p 9999:8000 xos
+ # sudo docker run -d --add-host="ctl:$(MYIP)" -p 9999:8000 xos
+ sudo docker run -i --tty --add-host="ctl:$(MYIP)" -p 9999:8000 xos
common_cloudlab:
make -C ../common -f Makefile.cloudlab
diff --git a/xos/configurations/test/Makefile.inside b/xos/configurations/test/Makefile.inside
index 9332016..2b24270 100644
--- a/xos/configurations/test/Makefile.inside
+++ b/xos/configurations/test/Makefile.inside
@@ -1,4 +1,4 @@
run_tests:
- cd /opt/xos/tosca/tests
- python ./alltests.py
-
+ bash /opt/xos/scripts/docker_setup_xos
+ supervisorctl stop observer
+ cd /opt/xos/tosca/tests; python ./alltests.py
diff --git a/xos/scripts/docker_setup_xos b/xos/scripts/docker_setup_xos
index 2ebd099..ed3e5e5 100755
--- a/xos/scripts/docker_setup_xos
+++ b/xos/scripts/docker_setup_xos
@@ -13,6 +13,5 @@
service postgresql start
wait_postgres
service supervisor start
-cd /opt/xos
-PUBLIC_HOSTNAME=`./xos-config.py get server_hostname $HOSTNAME`
-python manage.py runserver $PUBLIC_HOSTNAME:8000 --insecure
+
+exit 0