From a085e8cc182d49d5daca9efad74b5061cab61ecc Mon Sep 17 00:00:00 2001 From: Jacek Kowalski <Jacek@jacekk.info> Date: Mon, 17 Sep 2018 10:03:30 +0000 Subject: [PATCH] Update UniFi Controller to version 5.6.40 --- run.sh | 8 ++++++-- 1 files changed, 6 insertions(+), 2 deletions(-) diff --git a/run.sh b/run.sh index a04e068..f52b031 100755 --- a/run.sh +++ b/run.sh @@ -4,6 +4,10 @@ JAVA_OPTS="-Xmx1024m" fi -chown -Rf unifi:unifi /usr/lib/unifi/data +if [ `id -u` -eq 0 ]; then + chown -Rf unifi:unifi /usr/lib/unifi/data -exec sudo -u unifi java $JAVA_OPTS -jar /usr/lib/unifi/lib/ace.jar start + exec sudo -u unifi java $JAVA_OPTS -jar /usr/lib/unifi/lib/ace.jar start +else + exec java $JAVA_OPTS -jar /usr/lib/unifi/lib/ace.jar start +fi -- Gitblit v1.9.1