Skip to content

Commit

Permalink
Merge "Fix "service contrail-alarm-gen xxxx" command" into R3.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Zuul authored and opencontrail-ci-admin committed Mar 29, 2017
2 parents 09df3cd + 2fe2867 commit 01756f4
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/opserver/contrail-alarm-gen.initd.supervisord
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
#!/usr/bin/env bash

# chkconfig: 2345 99 01
# description: Juniper Network Virtualization Opserver
# description: Juniper Network Virtualization Alarm Generator

if [ -e /tmp/supervisord_analytics.sock ]; then
supervisorctl -s unix:///tmp/supervisord_analytics.sock ${1} `basename ${0}`
path='unix:///tmp/supervisord_analytics.sock'
else
supervisorctl -s unix:///var/run/supervisord_analytics.sock ${1} `basename ${0}`
path='unix:///var/run/supervisord_analytics.sock'
fi

alarm_gen_name=$(supervisorctl -s $path status | grep `basename ${0}` | awk {'print $1'})
supervisorctl -s $path ${1} $alarm_gen_name

0 comments on commit 01756f4

Please sign in to comment.