Adding a compose file to start onos and freeradius

Contains a test container to test whether radius
authenticates correctly. See compose/README.md
for more info.

Change-Id: Ifc489330049e3b41acd1b1006871c96aa889d89e
diff --git a/compose/README.md b/compose/README.md
index 0d65563..41c083d 100644
--- a/compose/README.md
+++ b/compose/README.md
@@ -1 +1,26 @@
 Various docker-compose files to assist in system testing.
+
+# About compose-auth-test
+
+# Freeradius
+Set the ip-range which will connect to the server and the server-secret in `clients.conf`, set the user/password combination in `users`. 
+
+## Start the freeradius and onos
+```
+$ docker-compose -f docker-compose-auth-test.yml up -d
+```
+
+## Start a test radius connection
+```
+$ docker-compose -f docker-compose-auth-test.yml up freeradius-test
+```
+The docker-compose-auth-test.yml contains a container called 'freeradius-test' which will send a auth-request to the server which after succes will print
+```
+freeradius-test_1  | Sending Access-Request of id 95 to 172.25.0.100 port 1812
+freeradius-test_1  |     User-Name = "user"
+freeradius-test_1  |     User-Password = "password"
+freeradius-test_1  |     NAS-IP-Address = 172.25.0.101
+freeradius-test_1  |     NAS-Port = 0
+freeradius-test_1  |     Message-Authenticator = 0x00000000000000000000000000000000
+freeradius-test_1  | rad_recv: Access-Accept packet from host 172.25.0.100 port 1812, id=95, length=20
+```
diff --git a/compose/data/clients.conf b/compose/data/clients.conf
new file mode 100644
index 0000000..7c0bbe1
--- /dev/null
+++ b/compose/data/clients.conf
@@ -0,0 +1,3 @@
+client  172.25.0.0/24 {
+ secret = SECRET
+}
diff --git a/compose/data/users b/compose/data/users
new file mode 100644
index 0000000..1e84143
--- /dev/null
+++ b/compose/data/users
@@ -0,0 +1 @@
+user Cleartext-Password := "password", MS-CHAP-Use-NTLM-Auth := 0
diff --git a/compose/docker-compose-auth-test.yml b/compose/docker-compose-auth-test.yml
new file mode 100644
index 0000000..3621249
--- /dev/null
+++ b/compose/docker-compose-auth-test.yml
@@ -0,0 +1,40 @@
+version: '2'
+
+services:
+
+ freeradius:
+  image: "marcelmaatkamp/freeradius"
+  ports:
+   - "1812:1812/udp"
+   - "1813:1813"
+   - "18120:18120"
+  volumes:
+   - "./data/clients.conf:/etc/raddb/clients.conf"
+   - "./data/users:/etc/raddb/users"
+  networks:
+   authnet:
+    ipv4_address: 172.25.0.100
+
+ onos:
+  image: "opencord/onos"
+  ports:
+   - "8101:8101" # ssh
+   - "6653:6653" # OF
+   - "8181:8181" # UI
+  networks:
+    authnet:
+     ipv4_address: 172.25.0.200
+
+ freeradius-test:
+  image: "marcelmaatkamp/freeradius"
+  command: "radtest user password freeradius 0 SECRET"
+  networks:
+   authnet:
+    ipv4_address: 172.25.0.101
+
+networks:
+  authnet:
+    driver: bridge
+    ipam:
+      config:
+      - subnet: 172.25.0.0/24