1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-03 01:23:49 +00:00
freebsd-ports/net-mgmt/smokeping/pkg-install
Lars Thegler c96404e983 - Update to 2.0.9
- Permanent uid/gid [1]
- Better handling of www uid [1]
- Update WWW: URL in pkg-descr [1]

PR:		ports/96310 [1]
Submitted by:	Gea-Suan Lin <gslin@gslin.org>
2006-07-26 12:55:58 +00:00

31 lines
547 B
Bash

#! /bin/sh
#
# $FreeBSD$
#
case $2 in
PRE-INSTALL)
if ! pw groupshow %%GROUP%% 2>/dev/null 1>&2; then
if pw groupadd %%GROUP%% -g %%GID%% ; then
echo 'Added group "%%GROUP%%".'
else
echo 'Adding group "%%GROUP%%" failed...'
exit 1
fi
fi
if ! pw usershow %%USER%% 2>/dev/null 1>&2; then
if pw useradd %%USER%% -u %%UID%% -g %%GROUP%% -h - \
-s /nonexistent -c "SmokePing Daemon"; \
then
echo 'Added user "%%USER%%".'
else
echo 'Adding user "%%USER%%" failed...'
exit 1
fi
fi
exit 0
;;
esac