diff options
author | Joachim Tingvold <joachim@tingvold.com> | 2016-03-25 15:51:28 +0100 |
---|---|---|
committer | Joachim Tingvold <joachim@tingvold.com> | 2016-03-25 15:51:28 +0100 |
commit | cd7f1eebc5702788545ee3f7adbc7eae7391437c (patch) | |
tree | f3d8fccf5845d903c9c07a5ffc4e36e490c00478 | |
parent | 1670071c058a2676a4a880a93acd57b35d6dc24e (diff) | |
parent | 875f3e404537de55d5b03abd3b0b9bec58c34d49 (diff) |
Merge branch 'master' of https://github.com/tech-server/tgmanage
-rw-r--r-- | web/etc/varnish/nms.vcl | 5 | ||||
-rw-r--r-- | web/nms.gathering.org/js/nms-map-handlers.js | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/web/etc/varnish/nms.vcl b/web/etc/varnish/nms.vcl index 0cddebd..53a9444 100644 --- a/web/etc/varnish/nms.vcl +++ b/web/etc/varnish/nms.vcl @@ -37,6 +37,7 @@ sub vcl_recv { return (hash); } + # Rosa magi sub vcl_hash { # Wheee. Legg til authorization-headeren i hashen. @@ -50,4 +51,8 @@ sub vcl_backend_response { if (beresp.http.x-ban) { ban("obj.http.x-url ~ " + beresp.http.x-ban); } + if (beresp.status != 200) { + set beresp.uncacheable = false; + set beresp.ttl = 5s; + } } diff --git a/web/nms.gathering.org/js/nms-map-handlers.js b/web/nms.gathering.org/js/nms-map-handlers.js index 868d26d..474e8ef 100644 --- a/web/nms.gathering.org/js/nms-map-handlers.js +++ b/web/nms.gathering.org/js/nms-map-handlers.js @@ -383,7 +383,7 @@ function dhcpUpdater() } try { for (var sw in nmsData.switches.switches) { - var c = "white"; + var c = blue; if (nmsData.dhcp.dhcp[sw] == undefined) { nmsMap.setSwitchColor(sw,c); continue; |