This repository has been archived on 2024-07-10. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
etckeeper/init.d/check-mk-free-2.1.0p6
root 33193b2b40 committing changes in /etc made by "apt install ./check-mk-free-2.1.0p6_0.bullseye_amd64.deb"
Packages with configuration changes:
+check-mk-free-2.1.0p6 0.bullseye amd64

Package changes:
+check-mk-free-2.1.0p6 0.bullseye amd64
2022-07-15 11:05:15 +02:00

64 lines
1.6 KiB
Bash
Executable File

#!/bin/sh
# Copyright (C) 2019 tribe29 GmbH - License: GNU General Public License v2
# This file is part of Checkmk (https://checkmk.com). It is subject to the terms and
# conditions defined in the file COPYING, which is part of this source code package.
# Startskript for OMD sites
### BEGIN INIT INFO
# Provides: omd-2.1.0p6.cfe
# Required-Start: $syslog
# Required-Stop: $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: OMD sites
# Description: Start and stop the sites of the OpenSource Monitoring
# Distribution (OMD)
### END INIT INFO
# -- start omd, if not disabled in /etc/default/omd
AUTOSTART=1
[ -r /etc/default/omd ] && . /etc/default/omd
VERSION=2.1.0p6.cfe
VER="-V $VERSION"
MSG="using omd version $VERSION"
OMD="/omd/versions/$VERSION/bin/omd"
case "$1" in
start)
if [ "$AUTOSTART" = "1" ]; then
echo "Starting all OMD monitoring sites $MSG:"
$OMD "$1" $VER
else
echo "OMD autostart disabled, skipping ..."
fi
;;
stop)
echo "Stopping all OMD monitoring sites $MSG:"
$OMD "$1" $VER
;;
restart)
echo "Restarting all OMD monitoring sites $MSG:"
$OMD "$1" $VER
;;
reload)
echo "Reloading all OMD monitoring sites $MSG:"
$OMD "$1" $VER
;;
status)
echo "Checking state of all OMD monitoring sites $MSG:"
$OMD "$1" $VER
;;
'')
echo "usage: $PROGNAME start|stop|restart|reload|status"
exit 1
;;
*)
echo "Doing $1 on all OMD monitoring sites $MSG:"
$OMD "$1" $VER
;;
esac