浏览代码

restart grafana after upgrade

The current script only tries to start the already running grafana process after an upgrade. This leads to errors due to changed js and css hashes while grafana is delivering the old ones. To load the new sources we need to restart grafana after an upgrade.
Ben Oswald 9 年之前
父节点
当前提交
1d2eb0f903
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      packaging/deb/control/postinst

+ 2 - 2
packaging/deb/control/postinst

@@ -10,9 +10,9 @@ startGrafana() {
     /bin/systemctl start grafana-server
 	elif [ -x "/etc/init.d/grafana-server" ]; then
 		if [ -x "`which invoke-rc.d 2>/dev/null`" ]; then
-			invoke-rc.d grafana-server start || true
+			invoke-rc.d grafana-server restart || true
 		else
-			/etc/init.d/grafana-server start || true
+			/etc/init.d/grafana-server restart || true
 		fi
 	fi
 }