NIFI-718: Add links to /etc/rc2.d when installing nifi as a linux service

This commit is contained in:
Mark Payne 2015-06-23 09:53:40 -04:00
parent 25146a5828
commit 1faca8c93e
1 changed files with 4 additions and 0 deletions

View File

@ -140,6 +140,10 @@ install() {
cp $0 $SVC_FILE
sed -i s:NIFI_HOME=.*:NIFI_HOME="$NIFI_HOME": $SVC_FILE
sed -i s:PROGNAME=.*:PROGNAME=$(basename "$0"): $SVC_FILE
rm -f /etc/rc2.d/S65${SVC_NAME}
ln -s /etc/init.d/$SVC_NAME /etc/rc2.d/S65${SVC_NAME}
rm -f /etc/rc2.d/K65${SVC_NAME}
ln -s /etc/init.d/$SVC_NAME /etc/rc2.d/K65${SVC_NAME}
echo Service $SVC_NAME installed
}