summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authorRene Wagner <rw@handhelds.org>2004-12-18 22:09:53 +0000
committerRene Wagner <rw@handhelds.org>2004-12-18 22:09:53 +0000
commit4634264be1512da17c2258ab5a3d542627e3f3e5 (patch)
tree373c507eaca44e5d84085ba82ea643d9c51cd833 /packages
parentc634d414b7579acce08a9814ff8b652214ff9d27 (diff)
ppp-dialin: fix user/group setup in postinst.
BKrev: 41c4aab1-zxS5421u1GnQ3HcL1JyyQ
Diffstat (limited to 'packages')
-rw-r--r--packages/ppp-dialin/ppp-dialin_0.1.bb41
1 files changed, 41 insertions, 0 deletions
diff --git a/packages/ppp-dialin/ppp-dialin_0.1.bb b/packages/ppp-dialin/ppp-dialin_0.1.bb
index e69de29bb2..0d2ee82589 100644
--- a/packages/ppp-dialin/ppp-dialin_0.1.bb
+++ b/packages/ppp-dialin/ppp-dialin_0.1.bb
@@ -0,0 +1,41 @@
+SECTION = "console/network"
+DESCRIPTION = "Enables PPP dial-in through a serial connection"
+MAINTAINER = "Rene Wagner <reenoo@gmx.de>"
+DEPENDS = "ppp"
+RDEPENDS = "ppp"
+PR = "r2"
+
+SRC_URI = "file://host-peer \
+ file://ppp-dialin"
+
+do_install() {
+ install -d ${D}/${sysconfdir}/ppp/peers
+ install -m 0644 ${WORKDIR}/host-peer ${D}/${sysconfdir}/ppp/peers/host
+
+ install -d ${D}/${sbindir}
+ install -m 0750 ${WORKDIR}/ppp-dialin ${D}/${sbindir}
+}
+
+
+# NOTE: adduser appears to be malfunctioning.
+# add ppp user when creating the group already.
+
+pkg_postinst() {
+if test "x$D" != "x"; then
+ exit 1
+else
+ addgroup ppp ppp
+ adduser --system --home /dev/null --no-create-home --empty-password --ingroup ppp -s /usr/sbin/ppp-dialin ppp
+ chgrp ppp /usr/sbin/ppp-dialin
+ chmod u+s /usr/sbin/ppp-dialin
+fi
+}
+
+pkg_postrm() {
+if test "x$D" != "x"; then
+ exit 1
+else
+ deluser ppp
+ delgroup ppp
+fi
+}