From 4d56a72b1f81d629f7d8baf4e4976607ba7706ed Mon Sep 17 00:00:00 2001 From: tteckster Date: Tue, 8 Mar 2022 09:51:10 -0500 Subject: [PATCH] Update grafana-install.sh --- setup/grafana-install.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/setup/grafana-install.sh b/setup/grafana-install.sh index be34f222..f14f16ea 100644 --- a/setup/grafana-install.sh +++ b/setup/grafana-install.sh @@ -72,6 +72,8 @@ apt-get update &>/dev/null apt-get install -y grafana &>/dev/null echo -e "${CM}${CL} \r" +PASS=$(grep -w "root" /etc/shadow | cut -b6); + if [[ $PASS != $ ]]; then echo -en "${GN} Customizing Container... " rm /etc/motd rm /etc/update-motd.d/10-uname @@ -84,10 +86,9 @@ ExecStart= ExecStart=-/sbin/agetty --autologin root --noclear --keep-baud tty%I 115200,38400,9600 \$TERM EOF systemctl daemon-reload -systemctl start grafana-server -systemctl enable grafana-server.service &>/dev/null systemctl restart $(basename $(dirname $GETTY_OVERRIDE) | sed 's/\.d//') echo -e "${CM}${CL} \r" + fi echo -en "${GN} Cleanup... " apt-get autoremove >/dev/null