[arch-commits] Commit in ufw/trunk (PKGBUILD rc.d service)

bpiotrowski at nymeria.archlinux.org bpiotrowski at nymeria.archlinux.org
Wed Jan 23 21:01:36 UTC 2013


    Date: Wednesday, January 23, 2013 @ 22:01:36
  Author: bpiotrowski
Revision: 82754

upgpkg: ufw 0.33-2

- remove sysvinit daemon
- start unit before sysinit.target

Modified:
  ufw/trunk/PKGBUILD
  ufw/trunk/service
Deleted:
  ufw/trunk/rc.d

----------+
 PKGBUILD |   11 +++-------
 rc.d     |   64 -------------------------------------------------------------
 service  |    5 ++++
 3 files changed, 9 insertions(+), 71 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2013-01-23 20:52:45 UTC (rev 82753)
+++ PKGBUILD	2013-01-23 21:01:36 UTC (rev 82754)
@@ -6,7 +6,7 @@
 
 pkgname=ufw
 pkgver=0.33
-pkgrel=1
+pkgrel=2
 pkgdesc="Uncomplicated and easy to use CLI tool for managing a netfilter firewall"
 arch=('any')
 url="https://launchpad.net/ufw"
@@ -23,11 +23,9 @@
         'usr/lib/ufw/user.rules'
         'usr/lib/ufw/user6.rules')
 source=(http://launchpad.net/$pkgname/$pkgver/$pkgver/+download/${pkgname}-${pkgver}.tar.gz
-        rc.d
         service)
-md5sums=('3747b453d76709e5a99da209fc0bb5f5'
-         '3d32964a23e0d6b3b7002272154bfad3'
-         'd125e918ce9a832c528e6982cf6f6d98')
+sha256sums=('5f85a8084ad3539b547bec097286948233188c971f498890316dec170bdd1da8'
+            'fdface6f4690e4748fbbd5661c02e1967a8750fdb23581d35516174017a3fe39')
 
 package() {
   cd $srcdir/$pkgname-$pkgver
@@ -37,10 +35,9 @@
 
   python2 setup.py install --root=$pkgdir
 
-  install -Dm755 $srcdir/rc.d $pkgdir/etc/rc.d/$pkgname
   install -Dm644 $srcdir/service $pkgdir/usr/lib/systemd/system/ufw.service
 
-  install -D -m755 $pkgdir/usr/sbin/$pkgname $pkgdir/usr/bin/$pkgname
+  install -Dm755 $pkgdir/usr/sbin/$pkgname $pkgdir/usr/bin/$pkgname
   rm -rf $pkgdir/usr/sbin
 
   chmod 644 $pkgdir/etc/ufw/*.rules $pkgdir/usr/lib/ufw/*.rules

Deleted: rc.d
===================================================================
--- rc.d	2013-01-23 20:52:45 UTC (rev 82753)
+++ rc.d	2013-01-23 21:01:36 UTC (rev 82754)
@@ -1,64 +0,0 @@
-#!/bin/bash
-
-. /etc/rc.conf
-. /etc/rc.d/functions
-
-[ -x /usr/bin/ufw ] || exit 0
-
-for s in "/usr/lib/ufw/ufw-init-functions" "/etc/ufw/ufw.conf" ; do
-    if [ -s "$s" ]; then
-        . "$s"
-    else
-        echo "Could not find $s (aborting)"
-        exit 1
-    fi
-done
-
-error=0
-case "$1" in
-start)
-    if [ "$ENABLED" = "yes" ] || [ "$ENABLED" = "YES" ]; then
-        stat_busy "Starting ufw"
-        if ! ufw_start; then
-            stat_fail
-        else
-            add_daemon ufw
-            stat_done
-        fi
-
-    else
-        echo "Skip starting firewall:" "ufw (not enabled)"
-    fi
-    ;;
-stop)
-    if [ "$ENABLED" = "yes" ] || [ "$ENABLED" = "YES" ]; then
-        stat_busy "Stopping ufw"
-        if ! ufw_stop; then
-            stat_fail
-        else
-            rm_daemon ufw
-            stat_done
-        fi
-    else
-        echo "Skip stopping firewall:" "ufw (not enabled)"
-    fi
-    ;;
-restart|force-reload)
-    stat_busy "Reloading ufw"
-    if ! ufw_reload; then
-        stat_fail
-    else
-        stat_done
-    fi
-    ;;
-status)
-    ufw_status
-    ;;
-*)
-    echo "Usage: /etc/rc.d/ufw {start|stop|restart|force-reload|status}"
-    exit 1
-    ;;
-esac
-
-exit 0
-

Modified: service
===================================================================
--- service	2013-01-23 20:52:45 UTC (rev 82753)
+++ service	2013-01-23 21:01:36 UTC (rev 82754)
@@ -1,5 +1,10 @@
 [Unit]
 Description=CLI Netfilter Manager
+DefaultDependencies=no
+After=systemd-sysctl.service
+Before=sysinit.target
+ConditionPathExists=|/etc/ufw/ufw.conf
+ConditionDirectoryNotEmpty=|/usr/lib/ufw
 
 [Service]
 Type=oneshot




More information about the arch-commits mailing list