opportunity: optional argument is the iface
authorJean Privat <jean@pryen.org>
Thu, 27 Apr 2017 14:47:20 +0000 (10:47 -0400)
committerJean Privat <jean@pryen.org>
Thu, 27 Apr 2017 14:47:56 +0000 (10:47 -0400)
Signed-off-by: Jean Privat <jean@pryen.org>

contrib/opportunity/src/opportunity_web.nit

index bbee410..dc0c2fe 100644 (file)
@@ -21,6 +21,10 @@ import privileges
 
 var iface = "localhost:8080"
 
+if args.not_empty then
+       iface = args.first
+end
+
 var vh = new VirtualHost(iface)
 vh.routes.add new Route("/rest/", new OpportunityRESTAction)
 vh.routes.add new Route("/static/", new FileServer("art"))