Make it easier to run the IT 47/10147/1
authorDave Tucker <djt@redhat.com>
Thu, 21 Aug 2014 17:55:33 +0000 (18:55 +0100)
committerDave Tucker <djt@redhat.com>
Thu, 21 Aug 2014 17:58:28 +0000 (18:58 +0100)
The IT can now be run locally using Docker and Fig

 fig start
 mvn verify -Pintegrationtest <options here>
 fig stop

On OSX this requires the use of boot2docker, but this is much easier and
lighterweight than cloning the docker-ovs repo.

Different versions of openvswitch can be used by editing fig.yml

Change-Id: If4aea173c1ce366ce901808992d1f88e5c8e1a58
Signed-off-by: Dave Tucker <djt@redhat.com>
README
fig.yml [new file with mode: 0644]

diff --git a/README b/README
index 2356030fbe5431aadb9b682f05631fbc35f05d69..4e84de038fe2b0facbef36145a20934781e8a5f6 100644 (file)
--- a/README
+++ b/README
@@ -94,3 +94,28 @@ Pre-requisites : JDK 1.7+, Maven 3+
    199 | Active | 80 | 1.0.0.SNAPSHOT | OVSDB Open_vSwitch Schema
    200 | Active | 80 | 1.0.0.SNAPSHOT | OVSDB hardware_vtep Schema
    201 | Active | 80 | 1.0.0.SNAPSHOT | OpenDaylight OVSDB Plugin
+
+Running The Integration Tests
+=============================
+
+To run the integration tests locally the following components are required:
+
+ - Docker
+ - Fig
+
+To install docker, follow the installation guide for your platform:
+   http://docs.docker.com/installation/
+
+To install fig:
+   http://www.fig.sh/install.html
+
+To run the integration tests:
+
+    mvn clean install
+    fig start
+    # OSX
+    mvn verify -Pintegrationtest -Dovsdbserver.ipaddress=$(boot2docker ip 2>/dev/null) -Dovsdbserver.port=6640
+    # Linux
+    mvn verify -Pintegrationtest -Dovsdbserver.ipaddress=127.0.0.1 -Dovsdbserver.port=6640
+    fig stop
+
diff --git a/fig.yml b/fig.yml
new file mode 100644 (file)
index 0000000..9c9a77a
--- /dev/null
+++ b/fig.yml
@@ -0,0 +1,6 @@
+ovs:
+ image: davetucker/docker-ovs:2.1.2
+ ports: 
+   - "6640:6640"
+ command: "/usr/bin/supervisord -n"
+ privileged: true