Skip to content

Commit

Permalink
log to syslog via logger
Browse files Browse the repository at this point in the history
  • Loading branch information
hobbyquaker committed Apr 29, 2018
1 parent a781caa commit 7c317c6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions addon_files/node-red/node-red
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ RED=$RED_DIR/red.js

SETTINGS=$ADDON_DIR/settings.js

LOG=/var/log/node-red.log

Stop () {
PSPID=`ps -o pid,comm,args | awk '{if($3 == "node-red" || $4 ~ /node-red/){print $1}}'`
if [ "$PSPID" != "" ]
Expand All @@ -33,7 +31,7 @@ Stop () {

Start () {
echo -n "Starting Node-RED: "
$NODE $RED -s $SETTINGS >> $LOG &
$NODE $RED -s $SETTINGS | logger -p user.info -t node-red &
logger -t homematic -p user.info "started node-red"
echo "OK"
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ccu-addon-node-red",
"version": "0.0.3",
"version": "0.0.4",
"description": "Node-RED packaged as Homematic CCU addon",
"repository": "github:hobbyquaker/ccu-addon-node-red",
"private": true,
Expand Down

0 comments on commit 7c317c6

Please sign in to comment.