From 0f41363740f8357030f6917319698c6339c1f90d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Przemek=20Draga=C5=84czuk?= Date: Fri, 14 Feb 2020 18:42:21 +0100 Subject: [PATCH] Dynamic port config --- src/main/java/tk/draganczuk/url/App.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/java/tk/draganczuk/url/App.java b/src/main/java/tk/draganczuk/url/App.java index 6cf03a4..456e1de 100644 --- a/src/main/java/tk/draganczuk/url/App.java +++ b/src/main/java/tk/draganczuk/url/App.java @@ -15,6 +15,8 @@ public class App { staticFiles.location("/public"); } + port(Integer.parseInt(System.getProperty("port", "4567"))); + get("/", (req, res) -> { res.redirect("/index.html"); return "Redirect";