aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStanislav Sedov <stas@FreeBSD.org>2007-04-10 19:32:35 +0000
committerStanislav Sedov <stas@FreeBSD.org>2007-04-10 19:32:35 +0000
commitcb49ebd8e8f00a08174fda9c89715158ec455c96 (patch)
treea2244f5e4e3042412b0a60334f9ba9a8bfaf43b6
parent38c7ca20d1ea6f48d44b0d3e6a022b9f88efc732 (diff)
downloadports-cb49ebd8e8f00a08174fda9c89715158ec455c96.tar.gz
ports-cb49ebd8e8f00a08174fda9c89715158ec455c96.zip
- Use static gid/uid.
Submitted by: kris
Notes
Notes: svn path=/head/; revision=189708
-rw-r--r--GIDs1
-rw-r--r--UIDs1
-rw-r--r--net-mgmt/flow-tools/Makefile4
-rw-r--r--net-mgmt/flow-tools/files/pkg-install.in5
4 files changed, 10 insertions, 1 deletions
diff --git a/GIDs b/GIDs
index faea22656b08..a4aa5a5206b4 100644
--- a/GIDs
+++ b/GIDs
@@ -66,6 +66,7 @@ rbldns:*:153:
sfs:*:171:
agk:*:172:
polipo:*:173:
+flowtools:*:174:
nagios:*:181:
moinmoin:*:192:
cups:*:193:
diff --git a/UIDs b/UIDs
index 6cb5ec7ddd10..c56d2f14811b 100644
--- a/UIDs
+++ b/UIDs
@@ -74,6 +74,7 @@ rbldns:*:153:153:rbldnsd pseudo-user:/nonexistent:/sbin/nologin
sfs:*:171:171:Self-Certifying File System:/nonexistent:/sbin/nologin
agk:*:172:172:AquaGateKeeper:/nonexistent:/nonexistent
polipo:*:173:173:polipo web cache:/nonexistent:/sbin/nologin
+flowtools:*:174:174:Flow-tools collector pseudo-user:/nonexistent:/sbin/nologin
nagios:*:181:181:Nagios pseudo-user:/var/spool/nagios:/sbin/nologin
moinmoin:*:192:192:MoinMoin User:/nonexistent:/sbin/nologin
cups:*:193:193:Cups Owner:/nonexistent:/sbin/nologin
diff --git a/net-mgmt/flow-tools/Makefile b/net-mgmt/flow-tools/Makefile
index 2adb7e0f827f..dff324563ff8 100644
--- a/net-mgmt/flow-tools/Makefile
+++ b/net-mgmt/flow-tools/Makefile
@@ -30,6 +30,8 @@ SUB_FILES= pkg-install pkg-deinstall
SUB_LIST= FLOW_CAPTURE_SPOOL="${FLOW_CAPTURE_SPOOL}" \
FLOW_CAPTURE_USER="${FLOW_CAPTURE_USER}" \
FLOW_CAPTURE_GROUP="${FLOW_CAPTURE_GROUP}" \
+ FLOW_CAPTURE_UID="${FLOW_CAPTURE_UID}" \
+ FLOW_CAPTURE_GID="${FLOW_CAPTURE_GID}" \
FLOW_CAPTURE_PIDDIR="${FLOW_CAPTURE_PIDDIR}"
USE_RC_SUBR= flow_capture
@@ -37,6 +39,8 @@ VARDIR?= ${DESTDIR}/var
FLOW_CAPTURE_SPOOL= ${VARDIR}/db/flows
FLOW_CAPTURE_USER= flowtools
FLOW_CAPTURE_GROUP= flowtools
+FLOW_CAPTURE_UID= 174
+FLOW_CAPTURE_GID= 174
FLOW_CAPTURE_PIDDIR= ${VARDIR}/run/flow-capture
.if defined(WITH_PGSQL)
diff --git a/net-mgmt/flow-tools/files/pkg-install.in b/net-mgmt/flow-tools/files/pkg-install.in
index dc913ca32fd8..3efd6d271982 100644
--- a/net-mgmt/flow-tools/files/pkg-install.in
+++ b/net-mgmt/flow-tools/files/pkg-install.in
@@ -8,6 +8,8 @@ PATH=/bin:/usr/sbin:/usr/bin:/usr/sbin
FLOW_CAPTURE_SPOOL="%%FLOW_CAPTURE_SPOOL%%"
FLOW_CAPTURE_USER="%%FLOW_CAPTURE_USER%%"
FLOW_CAPTURE_GROUP="%%FLOW_CAPTURE_GROUP%%"
+FLOW_CAPTURE_UID="%%FLOW_CAPTURE_UID%%"
+FLOW_CAPTURE_GID="%%FLOW_CAPTURE_GID%%"
FLOW_CAPTURE_PIDDIR="%%FLOW_CAPTURE_PIDDIR%%"
if [ -x /usr/sbin/nologin ]; then
@@ -23,7 +25,7 @@ pre-install() {
pw groupshow ${FLOW_CAPTURE_GROUP} > /dev/null 2>&1
if [ $? -ne 0 ]; then
echo -n "Creating '${FLOW_CAPTURE_GROUP}' group... "
- pw groupadd ${FLOW_CAPTURE_GROUP} -q
+ pw groupadd -n ${FLOW_CAPTURE_GROUP} -g ${FLOW_CAPTURE_GID} -q
if [ $? -eq 0 ]; then
echo "ok"
@@ -44,6 +46,7 @@ pre-install() {
if [ $? -ne 0 ]; then
echo -n "Creating '${FLOW_CAPTURE_USER}' user... "
pw useradd -n ${FLOW_CAPTURE_USER} -g ${FLOW_CAPTURE_GROUP} \
+ -u ${FLOW_CAPTURE_UID} \
-c "Flow-tools collector pseudo-user" \
-d "/var/empty" -s "${NOLOGIN}" -h - -q