Skip to content

Commit f38d8b9

Browse files
committed
Merge pull request #25 from jdrago999/patch-1
Make restart actually work
2 parents dc28896 + be6f2db commit f38d8b9

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

init.d/codedeploy-agent

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,13 @@ stop() {
4040
exit $?
4141
}
4242

43+
restart() {
44+
echo -n $"Restarting $prog:"
45+
cd $AGENT_ROOT
46+
nohup $BIN restart >/dev/null </dev/null 2>&1 # Try to restart the server
47+
exit $?
48+
}
49+
4350
status() {
4451
cd $AGENT_ROOT
4552
$BIN status # Status of the server
@@ -67,8 +74,7 @@ case "$1" in
6774
stop
6875
;;
6976
restart)
70-
stop
71-
start
77+
restart
7278
;;
7379
force-reload)
7480
stop

0 commit comments

Comments
 (0)