X-Original-To: alpine-user@lists.alpinelinux.org Received: from mail-ed1-f46.google.com (mail-ed1-f46.google.com [209.85.208.46]) by lists.alpinelinux.org (Postfix) with ESMTP id BD9E75C55B8 for ; Wed, 5 Sep 2018 04:50:22 +0000 (GMT) Received: by mail-ed1-f46.google.com with SMTP id f38-v6so4980472edd.8 for ; Tue, 04 Sep 2018 21:50:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=fRjKcdD0DwRWZl4dBhYbUQoVUojlNUSKUi/GkP2nSug=; b=MWwiE0DUT1XB7eQGYAj8EKPWKfKNjp7dzZS0u5YbVzK05vizhKFKS+HhOtlcH+Np/h pRjoeGxUs9bcI5p/FCEHHrcrw87a5FKRPxwa4SdT95+xbs7IJ+OXsoO4FG1KxaM2mT+4 VJ+jx6MBd6j7NEW3/hQx1eb3FjPDEPf0tmWYaYYixoT5si7+OW8XoEBFVVPSF/PTXgir sTqOJRrKlNvTovTN+olhoK5sDm8v8dKi52UsvaxPxiU5JQnDoeg4ueJwMWLRLLyjsgcJ gkC7iynshk5A3L9tR9sxLRScKp1Q+2LD5N4QJyH95XO8JL5X/uTljDLF6nQjEEdDF5Ft MUXA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=fRjKcdD0DwRWZl4dBhYbUQoVUojlNUSKUi/GkP2nSug=; b=Tk2bKitYhlF4e++3AX7M4HckV2JwjzWCqU+AE3zleoIkoydlc5gCmcwVnmVNruq/ch 1ZWH3WmpZuLL9embaBd5k30kekKiKZQ0Da/GCCTmYdORwGyz33rtPl4tYIZO4/8jTilc GFfG0OhFqLZlym7ym5WYd5I74uFRgSvmcKbNOloPjZAQCybY6Ze7kZnp7AQQtdg1nLEE 1uvIp+OAF1ItCGCt/EZ/LOZq5HUuvlHeAjWR2FnuNPDXXm7DP1I0E2GYhcHh497ldD/V pLdL6xKFG73FO2pl/L7+kPJGymLmcBz/6yR3DEs0MiqhC4iILWYm/hAla7Bu0b4Yui1N EYxg== X-Gm-Message-State: APzg51Bo3Y2WUxwONF/dcy8PCIwTXlIvMnoyF/ZmgbB+RYryP283weEZ kU8Y/JZdNiHy5Ae3e4IYcOaSAypFK32ooSjNa8AZsATJ X-Google-Smtp-Source: ANB0VdZ8RiXlDYSohRx/nq7/jzymxT5fkgb6n0yMJms08MjyTUfih6+4I2mO4aErR3A/0evVRat4t/g6Tlc142dD8fA= X-Received: by 2002:aa7:ca51:: with SMTP id j17-v6mr38828754edt.45.1536123021890; Tue, 04 Sep 2018 21:50:21 -0700 (PDT) X-Mailinglist: alpine-user Precedence: list List-Id: Alpine Development List-Unsubscribe: List-Post: List-Help: List-Subscribe: MIME-Version: 1.0 From: Bernard Mentink Date: Wed, 5 Sep 2018 16:50:09 +1200 Message-ID: Subject: [alpine-user] Init scripts To: alpine-user@lists.alpinelinux.org Content-Type: multipart/alternative; boundary="0000000000000d1b5a05751883b8" --0000000000000d1b5a05751883b8 Content-Type: text/plain; charset="UTF-8" Hi, I have an Alpine virtual machine running an OpenHab server. Unfortunately the server does not restart correctly after a power loss /restart. I suspect that it is because the service does not wait for the network to come up. I have to manually start the service after network is up. Can someone look at my current init script below and make suggestions to fix this? Thanks, #!/sbin/openrc-run depend() { need net } stop() { /home/bmentink/runtime/bin/stop } command="/home/bmentink/runtime/bin/start" # The special RC_SVCNAME variable contains the name of this service. pidfile="/run/${RC_SVCNAME}.pid" command_args="-p ${pidfile}" --0000000000000d1b5a05751883b8 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi,

I ha= ve an Alpine virtual machine running an OpenHab server. Unfortunately the s= erver does not restart correctly after a power loss /restart.
I su= spect that it is because the service does not wait for the network to come = up. I have to manually start the service after network is up.

= Can someone look at my current init script below and make suggestions to fi= x this?

Thanks,

#!/sbin/openrc-run
=C2=A0
depend() {
 need net
}
=C2=A0
stop() {
  /home/bmentink/runtime/bin/stop
} =20
=C2=A0
command=3D"/home/bmentink/runtime/bin/start"
=C2=A0
# The special RC_SVCNAME variable contains the name of this service.
pidfile=3D"/run/${RC_SVCNAME}.pid"
command_args=3D"-p ${pidfile}"
=C2=A0
--0000000000000d1b5a05751883b8-- --- Unsubscribe: alpine-user+unsubscribe@lists.alpinelinux.org Help: alpine-user+help@lists.alpinelinux.org ---