#!/sbin/openrc-run # Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 command="/usr/bin/uredir" command_background="yes" command_args="${OPTS}" description="UDP port redirector" name="UDP port redirector" user="${UREDIR_USER:-uredir}" group="${UREDIR_GROUP:-uredir}" pidfile="/run/uredir/${RC_SVCNAME}.pid" depend() { need net } start_post() { pgrep -n "${RC_SVCNAME%%.*}" > "${pidfile}" }