ports/96310: [PATCH] net/smokeping: Use fixed uid/gid
Gea-Suan Lin
gslin at gslin.org
Tue Apr 25 10:00:36 UTC 2006
>Number: 96310
>Category: ports
>Synopsis: [PATCH] net/smokeping: Use fixed uid/gid
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Tue Apr 25 10:00:30 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator: Gea-Suan Lin
>Release: FreeBSD 6.0-RELEASE-p2 i386
>Organization:
>Environment:
System: FreeBSD netnews.NCTU.edu.tw 6.0-RELEASE-p2 FreeBSD 6.0-RELEASE-p2 #4: Sun Jan 15 20:44:38 CST 2006
>Description:
* Use fixed uid/gid for smokeping:smokeping.
Please update porters-handbook at same time.
* Remove www detecting and add uid/gid code.
* Change Homepage URL.
* Bump PORTREVISION.
Port maintainer (lth at FreeBSD.org) is cc'd.
Generated with FreeBSD Port Tools 0.63
>How-To-Repeat:
>Fix:
--- smokeping-2.0.8_1.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/net/smokeping/Makefile /home/staff/gslin/work/smokeping/Makefile
--- /usr/ports/net/smokeping/Makefile Sat Apr 15 03:18:04 2006
+++ /home/staff/gslin/work/smokeping/Makefile Tue Apr 25 17:51:08 2006
@@ -7,6 +7,7 @@
PORTNAME= smokeping
PORTVERSION= 2.0.8
+PORTREVISION= 1
CATEGORIES= net www
MASTER_SITES= http://people.ee.ethz.ch/~oetiker/webtools/smokeping/pub/
@@ -119,15 +120,12 @@
PKGDEINSTALL= ${WRKDIR}/pkg-deinstall
USER= smokeping
+SMOKEPING_UID= 116
GROUP= smokeping
-WWW_USER= www
-WWW_UID= 80
-WWW_GROUP= www
-WWW_GID= 80
-
-FILES_SUB= USER=${USER} GROUP=${GROUP} \
- WWW_USER=${WWW_USER} WWW_UID=${WWW_UID} \
- WWW_GROUP=${WWW_GROUP} WWW_GID=${WWW_GID} \
+SMOKEPING_GID= 116
+
+FILES_SUB= USER=${USER} UID=${SMOKEPING_UID} \
+ GROUP=${GROUP} GID=${SMOKEPING_GID} \
PERL=${PERL} PREFIX=${PREFIX}
DOC1= CHANGES CONTRIBUTORS COPYING COPYRIGHT README TODO
diff -ruN --exclude=CVS /usr/ports/net/smokeping/pkg-descr /home/staff/gslin/work/smokeping/pkg-descr
--- /usr/ports/net/smokeping/pkg-descr Thu Oct 13 14:38:45 2005
+++ /home/staff/gslin/work/smokeping/pkg-descr Tue Apr 25 17:35:47 2006
@@ -2,7 +2,7 @@
daemon process which organizes the latency measurements and a CGI
which presents the graphs.
-WWW: http://people.ee.ethz.ch/~oetiker/webtools/smokeping/
+WWW: http://oss.oetiker.ch/smokeping/
--lars
lars at thegler.dk
diff -ruN --exclude=CVS /usr/ports/net/smokeping/pkg-install /home/staff/gslin/work/smokeping/pkg-install
--- /usr/ports/net/smokeping/pkg-install Tue May 18 21:23:20 2004
+++ /home/staff/gslin/work/smokeping/pkg-install Tue Apr 25 17:27:33 2006
@@ -5,29 +5,8 @@
case $2 in
PRE-INSTALL)
- if ! pw groupshow %%WWW_GROUP%% 2>/dev/null 1>&2; then
- if pw groupadd %%WWW_GROUP%% -g %%WWW_GID%%; then
- echo 'Added group "%%WWW_GROUP%%".'
- else
- echo 'Adding group "%%WWW_GROUP%%" failed...'
- exit 1
- fi
- fi
-
- if ! pw usershow %%WWW_USER%% 2>/dev/null 1>&2; then
- if pw useradd %%WWW_USER%% -u %%WWW_UID%% -g %%WWW_GROUP%% -h - \
- -s /sbin/nologin -d /nonexistent \
- -c "World Wide Web Owner"; \
- then
- echo 'Added user "%%WWW_USER%%".'
- else
- echo 'Adding user "%%WWW_USER%%" failed...'
- exit 1
- fi
- fi
-
if ! pw groupshow %%GROUP%% 2>/dev/null 1>&2; then
- if pw groupadd %%GROUP%%; then
+ if pw groupadd %%GROUP%% -g %%GID%% ; then
echo 'Added group "%%GROUP%%".'
else
echo 'Adding group "%%GROUP%%" failed...'
@@ -36,7 +15,7 @@
fi
if ! pw usershow %%USER%% 2>/dev/null 1>&2; then
- if pw useradd %%USER%% -g %%GROUP%% -h - \
+ if pw useradd %%USER%% -u %%UID%% -g %%GROUP%% -h - \
-s /nonexistent -c "SmokePing Daemon"; \
then
echo 'Added user "%%USER%%".'
--- smokeping-2.0.8_1.patch ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list