mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-10 08:14:09 -09:00
package/openssh: tidy up init script
* Use long options for start-stop-daemon * Avoid --quiet, except for reload where the "stopping" message could be confusing Signed-off-by: Fiona Klute (WIWA) <fiona.klute@gmx.de> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
committed by
Thomas Petazzoni
parent
02d8e072d1
commit
1f743f4004
@@ -16,8 +16,8 @@ start() {
|
|||||||
/usr/bin/ssh-keygen -A
|
/usr/bin/ssh-keygen -A
|
||||||
|
|
||||||
printf "Starting %s: " "$DAEMON"
|
printf "Starting %s: " "$DAEMON"
|
||||||
start-stop-daemon -S -q -p "$PIDFILE" \
|
start-stop-daemon --start --pidfile "$PIDFILE" \
|
||||||
-x "/usr/sbin/$DAEMON"
|
--exec "/usr/sbin/$DAEMON"
|
||||||
status=$?
|
status=$?
|
||||||
if [ "$status" -eq 0 ]; then
|
if [ "$status" -eq 0 ]; then
|
||||||
echo "OK"
|
echo "OK"
|
||||||
@@ -29,8 +29,8 @@ start() {
|
|||||||
|
|
||||||
stop() {
|
stop() {
|
||||||
printf "Stopping sshd: "
|
printf "Stopping sshd: "
|
||||||
start-stop-daemon -K -q -p "$PIDFILE" \
|
start-stop-daemon --stop --pidfile "$PIDFILE" \
|
||||||
-x "/usr/sbin/$DAEMON"
|
--exec "/usr/sbin/$DAEMON"
|
||||||
status=$?
|
status=$?
|
||||||
if [ "$status" -eq 0 ]; then
|
if [ "$status" -eq 0 ]; then
|
||||||
echo "OK"
|
echo "OK"
|
||||||
@@ -51,8 +51,8 @@ restart() {
|
|||||||
|
|
||||||
reload() {
|
reload() {
|
||||||
printf "Reloading sshd config: "
|
printf "Reloading sshd config: "
|
||||||
start-stop-daemon -K --signal HUP -q -p "$PIDFILE" \
|
start-stop-daemon --stop --signal HUP -q --pidfile "$PIDFILE" \
|
||||||
-x "/usr/sbin/$DAEMON"
|
--exec "/usr/sbin/$DAEMON"
|
||||||
status=$?
|
status=$?
|
||||||
if [ "$status" -eq 0 ]; then
|
if [ "$status" -eq 0 ]; then
|
||||||
echo "OK"
|
echo "OK"
|
||||||
|
|||||||
Reference in New Issue
Block a user