[arch-commits] Commit in ejabberd/trunk (PKGBUILD ejabberd.install sysuser.conf)

Sergej Pupykin spupykin at archlinux.org
Tue Feb 10 15:22:56 UTC 2015


    Date: Tuesday, February 10, 2015 @ 16:22:55
  Author: spupykin
Revision: 127467

upgpkg: ejabberd 14.12-2

upd

Added:
  ejabberd/trunk/sysuser.conf
Modified:
  ejabberd/trunk/PKGBUILD
  ejabberd/trunk/ejabberd.install

------------------+
 PKGBUILD         |    9 ++++-----
 ejabberd.install |   18 +++++-------------
 sysuser.conf     |    3 +++
 3 files changed, 12 insertions(+), 18 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2015-02-10 14:35:44 UTC (rev 127466)
+++ PKGBUILD	2015-02-10 15:22:55 UTC (rev 127467)
@@ -5,7 +5,7 @@
 
 pkgname=ejabberd
 pkgver=14.12
-pkgrel=1
+pkgrel=2
 pkgdesc="Jabber server written in Erlang"
 arch=('x86_64' 'i686')
 url="http://www.ejabberd.im/"
@@ -44,7 +44,7 @@
 	"git://github.com/processone/p1_utils"
 	"$pkgname.logrotate"
 	"ejabberd.service"
-	"https://github.com/processone/ejabberd/commit/7bdc1151b.patch")
+	"sysuser.conf")
 md5sums=('afa0961e10e136664576e841b0a675df'
          'SKIP'
          'SKIP'
@@ -71,13 +71,11 @@
          'SKIP'
          'f97c8a96160f30e0aecc9526c12e6606'
          'a437aff9d7d477fb036d527205617e18'
-         '1f803ad9831aa2fa55d8a307642371cc')
+         '458fc41be4adb9554a53b8f9ae05fbee')
 
 prepare() {
   cd "$srcdir/$pkgname-$pkgver"
 
-#  patch -p1 <$srcdir/7bdc1151b.patch
-
   mkdir -p "$srcdir/$pkgname-$pkgver/deps"
   for i in goldrush lager p1_cache_tab p1_iconv p1_pam \
            p1_stringprep p1_tls p1_xml p1_yaml p1_zlib xmlrpc \
@@ -114,6 +112,7 @@
   chmod a+rx "$pkgdir/usr/bin/ejabberdctl" "$pkgdir/usr/lib/ejabberd/priv/bin/captcha.sh"
   rm -rf "$pkgdir/var/lock" "$pkgdir/usr/sbin"
   install -Dm0644 $srcdir/ejabberd.service $pkgdir/usr/lib/systemd/system/ejabberd.service
+  install -Dm644 $srcdir/sysuser.conf "$pkgdir"/usr/lib/sysusers.d/ejabberd.conf
   # workaround
   ln -s mod_configure.beam $pkgdir/usr/lib/ejabberd/ebin/configure.beam
 }

Modified: ejabberd.install
===================================================================
--- ejabberd.install	2015-02-10 14:35:44 UTC (rev 127466)
+++ ejabberd.install	2015-02-10 15:22:55 UTC (rev 127467)
@@ -1,8 +1,7 @@
 post_install() {
-  groupadd -r jabber
-  useradd -r -G jabber -d /var/lib/ejabberd ejabberd
-  chown -R ejabberd.jabber var/log/ejabberd
-  chown -R ejabberd.jabber var/lib/ejabberd
+  systemd-sysusers ejabberd.conf
+  chown -R ejabberd:jabber var/log/ejabberd
+  chown -R ejabberd:jabber var/lib/ejabberd
   chown root:ejabberd \
     etc/ejabberd/ejabberd.yml \
     etc/ejabberd/ejabberdctl.cfg \
@@ -11,8 +10,8 @@
 }
 
 post_upgrade() {
-  chown -R ejabberd.jabber var/log/ejabberd
-  chown -R ejabberd.jabber var/lib/ejabberd
+  chown -R ejabberd:jabber var/log/ejabberd
+  chown -R ejabberd:jabber var/lib/ejabberd
   chown root:ejabberd \
     etc/ejabberd/ejabberd.yml \
     etc/ejabberd/ejabberdctl.cfg \
@@ -20,10 +19,3 @@
     usr/lib/ejabberd/priv/bin/epam
   echo "!!! it is major update. Config must be converted to yaml format."
 }
-
-post_remove() {
-  userdel ejabberd
-  groupdel jabber
-}
-
-# vim:set ts=2 sw=2 et:

Added: sysuser.conf
===================================================================
--- sysuser.conf	                        (rev 0)
+++ sysuser.conf	2015-02-10 15:22:55 UTC (rev 127467)
@@ -0,0 +1,3 @@
+g jabber     17     -            -
+u ejabberd   -      -            /var/lib/ejabberd
+m ejabberd   jabber



More information about the arch-commits mailing list