major update not sure
[vsorcdistro/.git] / scripts / routerflows.sh
diff --git a/scripts/routerflows.sh b/scripts/routerflows.sh
new file mode 100755 (executable)
index 0000000..ed21cbc
--- /dev/null
@@ -0,0 +1,18 @@
+#!/bin/bash
+#Setting address
+curl -X POST -d '{"address":"172.16.10.1/24"}' http://localhost:8080/router/0000000000000002
+curl -X POST -d '{"address": "172.16.30.1/24"}' http://localhost:8080/router/0000000000000002
+curl -X POST -d '{"address": "192.168.10.1/24"}' http://localhost:8080/router/0000000000000002
+curl -X POST -d '{"address":"172.16.20.1/24"}' http://localhost:8080/router/0000000000000001
+curl -X POST -d '{"address": "172.16.30.30/24"}' http://localhost:8080/router/0000000000000001
+curl -X POST -d '{"address": "192.168.30.1/24"}' http://localhost:8080/router/0000000000000003
+curl -X POST -d '{"address": "192.168.10.20/24"}' http://localhost:8080/router/0000000000000003
+
+#Setting default routes
+curl -X POST -d '{"gateway": "172.16.30.1"}' http://localhost:8080/router/0000000000000001
+curl -X POST -d '{"gateway": "172.16.30.30"}' http://localhost:8080/router/0000000000000002
+curl -X POST -d '{"gateway": "192.168.10.1"}' http://localhost:8080/router/0000000000000003
+
+#Setting static routes
+curl -X POST -d '{"destination": "192.168.30.0/24", "gateway": "192.168.10.20"}' http://localhost:8080/router/0000000000000002
+