[notify] openntpd: new user/group

The default user and group is 'ntp'. Please rename the old user and
group (_ntp).

Adopted the port from Brett.
This commit is contained in:
Simon Gloßner 2008-06-18 02:27:51 +02:00
parent 10203346e3
commit 7cb63bc48d
5 changed files with 30 additions and 26 deletions

View File

@ -1,2 +1,2 @@
ec25b21c39d0c4e94f1d48229acd9283 ntpd
6e76cfac0e9fb9bb727c49a98dcf898b ntpd
afc34175f38d08867c1403d9008600b3 openntpd-3.9p1.tar.gz

View File

@ -1,20 +1,23 @@
# Description: portable version of openbsd's ntpd implementation
# URL: http://www.openntpd.org/
# Maintainer: Simon Gloßner, viper at hometux dot de
# Packager: Matt Housh, jaeger at morpheus dot net
# Maintainer: Brett Goulder, predatorfreak at dcaf-security dot org
name=openntpd
version=3.9p1
release=1
release=2
source=(ftp://ftp.openbsd.org/pub/OpenBSD/OpenNTPD/$name-$version.tar.gz \
ntpd)
build() {
install -D -m 0755 ntpd $PKG/etc/rc.d/ntpd
cd $name-$version
./configure \
--prefix=/usr \
--sysconfdir=/etc
make
make DESTDIR=$PKG install
cd $name-$version
./configure \
--prefix=/usr \
--sysconfdir=/etc \
--with-privsep-user=ntp
make
make DESTDIR=$PKG install
install -D -m 0755 $SRC/ntpd $PKG/etc/rc.d/ntpd
}

View File

@ -1,15 +1,19 @@
REQUIREMENTS
README for openntpd
PRE-INSTALL
openntpd expects to have a user and group dedicated to it. By default, _ntp. To
create them, use the following or similar commands, edited to your needs.
POST-INSTALL
# groupadd -g 83 _ntp
# useradd -g _ntp -u 83 -c "NTP Daemon" -d /var/empty -s /bin/false _ntp
Create the necessary user 'ntp' and its group 'ntp'.
*NOTE*
groupadd ntp
useradd -g ntp -d /var/empty -s /bin/false ntp
passwd -l ntp
A post-install script has been added to the port which takes care of the
above.
MISCELLANEOUS
Have a look at the start/stop script if you don't like ntpd setting
the time immediately at startup. That allows for a large time
correction. Disable that feature by removing the '-s' option.

View File

@ -1,14 +1,11 @@
#!/bin/sh
#
# /etc/rc.d/ntpd: start/stop ntp daemon
# /etc/rc.d/ntpd: start/stop ntpd daemon
#
# comment or clear $NTPD_OPTS to disable initial clock set on startup
NTPD_OPTS="-s"
case $1 in
start)
/usr/sbin/ntpd $NTPD_OPTS
/usr/sbin/ntpd -s
;;
stop)
killall -q /usr/sbin/ntpd

View File

@ -1,5 +1,5 @@
#!/bin/sh
/usr/sbin/groupadd -g 83 _ntp
/usr/sbin/useradd -g _ntp -u 83 -c "NTP Daemon" -d /var/empty -s /bin/false _ntp
/usr/bin/passwd -l _ntp
/usr/sbin/groupadd ntp
/usr/sbin/useradd -g ntp -d /var/empty -s /bin/false ntp
/usr/bin/passwd -l ntp