Page MenuHomeDevCentral

ensure-eggdrops-are-live.sh
No OneTemporary

ensure-eggdrops-are-live.sh

#!/bin/sh
# -------------------------------------------------------------
# Eggdrop liveness checker
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Nasqueron
# License: Trivial work, not eligible to copyright
# Source file: roles/viperserv/eggdrop/files/ensure-eggdrops-are-live.sh
# -------------------------------------------------------------
#
# <auto-generated>
# This file is managed by our rOPS SaltStack repository.
#
# Changes to this file may cause incorrect behavior
# and will be lost if the state is redeployed.
# </auto-generated>
while IFS=' ' read -r eggdrop; do
# Skip blank lines and comment lines
take_first_character="?"
first_character=${eggdrop%"${eggdrop#${take_first_character}}"}
if [ "$first_character" = "#" ]; then
continue
elif [ "$eggdrop" = "" ]; then
continue
fi
service eggdrop status "$eggdrop" > /dev/null
status=$?
if [ $status -ne 0 ]; then
service eggdrop restart "$eggdrop"
fi
done < /usr/local/etc/eggdrops-live.conf

File Metadata

Mime Type
text/x-shellscript
Expires
Sat, Nov 7, 18:19 (1 w, 1 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
4094091
Default Alt Text
ensure-eggdrops-are-live.sh (1 KB)

Event Timeline