[rbldnsd] Rename systemctl-rbldnsd to rbldnsctl (#807504)

Paul Howarth pghmcfc at fedoraproject.org
Tue Apr 17 22:59:53 UTC 2012


commit 2a1d2f67a491148bb4e124bfb040a36d7344b2fd
Author: Paul Howarth <paul at city-fan.org>
Date:   Tue Apr 17 23:59:16 2012 +0100

    Rename systemctl-rbldnsd to rbldnsctl (#807504)

 README.systemd                 |   34 +++++++++++++++++-----------------
 systemctl-rbldnsd => rbldnsctl |   24 ++++++++++++------------
 rbldnsd.conf                   |    2 +-
 rbldnsd.spec                   |   17 ++++++++++-------
 4 files changed, 40 insertions(+), 37 deletions(-)
---
diff --git a/README.systemd b/README.systemd
index e56cef1..474f5f5 100644
--- a/README.systemd
+++ b/README.systemd
@@ -3,59 +3,59 @@ Using rbldnsd with systemd
 
 The traditional SysV initscript shipped with rbldnsd supports using
 multiple instances with arbitrary command lines. This is difficult
-to achieve with systemd so a wrapper script, systemctl-rbldnsd, has
-been provided to assist with the creation and use of native systemd
-unit files for each required instance, using exactly the same
-configuration in /etc/sysconfig/rbldnsd as the SysV initscript used.
+to achieve with systemd so a wrapper script, rbldnsctl, has been
+provided to assist with the creation and use of native systemd unit
+files for each required instance, using exactly the same configuration
+in /etc/sysconfig/rbldnsd as the SysV initscript used.
 
 Having edited /etc/sysconfig/rbldnsd to specify the rbldnsd
 instance(s) required, individual unit files for each instance can be
 created by:
 
-  systemctl-rbldnsd create
+  rbldnsctl create
 
 This creates unit files /etc/systemd/system/rbldnsd-<instancename>.service
 for each required instance. These units can then be manipulated
 individually using /bin/systemctl as usual, or all at once by using
-other systemctl-rbldnsd commands:
+other rbldnsctl commands:
 
-  systemctl-rbldnsd enable
+  rbldnsctl enable
 
 This enables all configured rbldnsd instances to start at boot time
 (equivalent of chkconfig rbldnsd on).
  
-  systemctl-rbldnsd disable
+  rbldnsctl disable
 
 This disables all configured rbldnsd instances from starting at boot time
 (equivalent of chkconfig rbldnsd off).
  
-  systemctl-rbldnsd start
+  rbldnsctl start
 
 This starts all configured rbldnsd instances immediately
 (equivalent of service rbldnsd start).
  
-  systemctl-rbldnsd stop
+  rbldnsctl stop
 
 This stops all configured rbldnsd instances
 (equivalent of service rbldnsd stop).
  
-  systemctl-rbldnsd reload
+  rbldnsctl reload
 
 This reloads all configured rbldnsd instances
 (equivalent of service rbldnsd reload).
  
-  systemctl-rbldnsd restart
+  rbldnsctl restart
 
 This restarts all configured rbldnsd instances
 (equivalent of service rbldnsd restart).
  
-  systemctl-rbldnsd condrestart
-  systemctl-rbldnsd try-restart
+  rbldnsctl condrestart
+  rbldnsctl try-restart
 
 These restart all configured rbldnsd instances immediately, if they are
 already running (equivalent of service rbldnsd condrestart).
  
-  systemctl-rbldnsd status
+  rbldnsctl status
 
 This shows status of all configured rbldnsd instances
 (equivalent of service rbldnsd status).
@@ -64,13 +64,13 @@ When editing /etc/sysconfig/rbldnsd to specify rbldnsd instance options,
 bear in mind:
 
 * systemd prefers the daemons it controls not to fork, so the unit files
-  created by systemctl-rbldnsd start rbldnsd with the "-n" option to prevent
+  created by rbldnsctl start rbldnsd with the "-n" option to prevent
   it from forking; this also means that systemd knows the PIDs of all
   instances itself, so there is no need to specify any forking/pidfile related
   options in /etc/sysconfig/rbldnsd
 
 * if you want just a single instance of rbldnsd and use the traditional "-"
-  identifier for it, systemctl-rbldnsd will create a unit file
+  identifier for it, rbldnsctl will create a unit file
   /etc/systemd/system/rbldnsd-single.service, i.e. the instance name will be
   set to "single"
 
diff --git a/systemctl-rbldnsd b/rbldnsctl
old mode 100644
new mode 100755
similarity index 88%
rename from systemctl-rbldnsd
rename to rbldnsctl
index a3fc118..75b4808
--- a/systemctl-rbldnsd
+++ b/rbldnsctl
@@ -1,42 +1,42 @@
 #!/bin/bash
 #
-# systemctl-rbldnsd : helper script for managing rbldnsd instances with systemd
+# rbldnsctl : helper script for managing rbldnsd instances with systemd
 #
 # Configuration is via the RBLDNSD variable in /etc/sysconfig/rbldnsd,
 # exactly as used with the traditional sysv initscript.
 #
 # Usage:
 #
-# systemctl-rbldnsd create
+# rbldnsctl create
 #   Creates unit files /etc/systemd/system/rbldnsd-<instance>.service
 #   for each configured rbldnsd instance
 #
-# systemctl-rbldnsd enable
+# rbldnsctl enable
 #   Enables (via systemctl) all configured rbldnsd instances to start
 #   at boot time
 #
-# systemctl-rbldnsd disable
+# rbldnsctl disable
 #   Disables (via systemctl) all configured rbldnsd instances from
 #   starting at boot time
 #
-# systemctl-rbldnsd start
+# rbldnsctl start
 #   Starts (via systemctl) all configured rbldnsd instances immediately
 #
-# systemctl-rbldnsd stop
+# rbldnsctl stop
 #   Stop (via systemctl) all configured rbldnsd instances immediately
 #
-# systemctl-rbldnsd reload
+# rbldnsctl reload
 #   Reloads (via systemctl) all configured rbldnsd instances immediately
 #
-# systemctl-rbldnsd restart
+# rbldnsctl restart
 #   Restarts (via systemctl) all configured rbldnsd instances immediately
 #
-# systemctl-rbldnsd condrestart
-# systemctl-rbldnsd try-restart
+# rbldnsctl condrestart
+# rbldnsctl try-restart
 #   Restarts (via systemctl) all configured rbldnsd instances immediately,
 #   if they are already running
 #
-# systemctl-rbldnsd status
+# rbldnsctl status
 #   Shows status of all configured rbldnsd instances
 #
 PATH=/sbin:/bin:/usr/bin:/usr/sbin
@@ -46,7 +46,7 @@ PATH=/sbin:/bin:/usr/bin:/usr/sbin
 
 # Check that configuration has been set up (RBLDNSD set in /etc/sysconfig/rbldnsd)
 if [ -z "$RBLDNSD" ]; then
-	echo "systemctl-rbldnsd: RBLDNSD not configured in /etc/sysconfig/rbldnsd" >&2
+	echo "rbldnsctl: RBLDNSD not configured in /etc/sysconfig/rbldnsd" >&2
 	exit 6
 fi
 
diff --git a/rbldnsd.conf b/rbldnsd.conf
index 46a8c33..db62404 100644
--- a/rbldnsd.conf
+++ b/rbldnsd.conf
@@ -1,5 +1,5 @@
 # This is boilerplate text for rbldnsd unit files, which can be
-# created using "systemctl-rbldnsd create" based on the traditional
+# created using "rbldnsctl create" based on the traditional
 # configuration variable RBLDNSD as defined in /etc/sysconfig/rbldnsd
 
 [Unit]
diff --git a/rbldnsd.spec b/rbldnsd.spec
index 805ab63..9653ca0 100644
--- a/rbldnsd.spec
+++ b/rbldnsd.spec
@@ -11,14 +11,14 @@
 Summary:	Small, fast daemon to serve DNSBLs
 Name:		rbldnsd
 Version:	0.996b
-Release:	7%{?dist}
+Release:	8%{?dist}
 License:	GPLv2+
 Group:		System Environment/Daemons
 URL:		http://www.corpit.ru/mjt/rbldnsd.html
 Source0:	http://www.corpit.ru/mjt/rbldnsd/rbldnsd_%{version}.tar.gz
 Source1:	rbldnsd.init
 Source2:	rbldnsd.conf
-Source3:	systemctl-rbldnsd
+Source3:	rbldnsctl
 Source4:	README.systemd
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(id -nu)
 BuildRequires:	gawk, zlib-devel
@@ -61,7 +61,7 @@ install -p -m 644 rbldnsd.8			%{buildroot}%{_mandir}/man8/
 install -p -m 644 debian/rbldnsd.default	%{buildroot}%{_sysconfdir}/sysconfig/rbldnsd
 %if %{use_systemd}
 install -p -m 644 rbldnsd.conf			%{buildroot}/etc/systemd/
-install -p -m 755 systemctl-rbldnsd		%{buildroot}%{_sbindir}/
+install -p -m 755 rbldnsctl			%{buildroot}%{_sbindir}/
 %else
 install -p -m 755 rbldnsd.init			%{buildroot}%{_initrddir}/rbldnsd
 %endif
@@ -97,8 +97,8 @@ fi
 if [ $1 -eq 0 ]; then
 	# Package removal, not upgrade
 %if %{use_systemd}
-	%{_sbindir}/systemctl-rbldnsd stop &>/dev/null || :
-	%{_sbindir}/systemctl-rbldnsd disable &>/dev/null || :
+	%{_sbindir}/rbldnsctl stop &>/dev/null || :
+	%{_sbindir}/rbldnsctl disable &>/dev/null || :
 %else
 	%{_initrddir}/rbldnsd stop &>/dev/null || :
 	/sbin/chkconfig --del rbldnsd || :
@@ -112,7 +112,7 @@ fi
 if [ $1 -ge 1 ]; then
 	# Package upgrade, not uninstall
 %if %{use_systemd}
-	%{_sbindir}/systemctl-rbldnsd try-restart &>/dev/null || :
+	%{_sbindir}/rbldnsctl try-restart &>/dev/null || :
 %else
 	%{_initrddir}/rbldnsd condrestart &>/dev/null || :
 %endif
@@ -128,12 +128,15 @@ fi
 %if %{use_systemd}
 %doc README.systemd
 %config(noreplace) %{_sysconfdir}/systemd/rbldnsd.conf
-%{_sbindir}/systemctl-rbldnsd
+%{_sbindir}/rbldnsctl
 %else
 %{_initrddir}/rbldnsd
 %endif
 
 %changelog
+* Tue Apr 17 2012 Paul Howarth <paul at city-fan.org> 0.996b-8
+- rename systemctl-rbldnsd to rbldnsctl (#807504)
+
 * Tue Apr 17 2012 Paul Howarth <paul at city-fan.org> 0.996b-7
 - use native systemd init from F-17 onwards (see README.systemd)
 


More information about the scm-commits mailing list