ctdb-scripts: Drop event script CTDB_MANAGED_<service> variables
authorMartin Schwenke <martin@meltin.net>
Sat, 7 Jul 2018 10:06:47 +0000 (20:06 +1000)
committerAmitay Isaacs <amitay@samba.org>
Wed, 11 Jul 2018 09:48:39 +0000 (11:48 +0200)
Enable required event scripts to manage services.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
ctdb/config/events/README
ctdb/config/events/legacy/06.nfs.script
ctdb/config/events/legacy/31.clamd.script
ctdb/config/events/legacy/40.vsftpd.script
ctdb/config/events/legacy/41.httpd.script
ctdb/config/events/legacy/49.winbind.script
ctdb/config/events/legacy/50.samba.script
ctdb/config/events/legacy/60.nfs.script
ctdb/config/events/legacy/70.iscsi.script
ctdb/config/script.options
ctdb/doc/ctdb-script.options.5.xml

index 88d5da45b6e8aef708b2abd677af32cd753bf8cb..766cb4f106480f9485263eac09fe499b5359cbc5 100644 (file)
@@ -68,8 +68,7 @@ startup
        If the "startup" event fails then CTDB will retry it until it
        succeeds.  There is no limit on the number of retries.
 
-       Example: 50.samba uses this event to start the Samba daemon if
-       CTDB_MANAGES_SAMBA=yes.
+       Example: 50.samba uses this event to start the Samba daemon.
 
 shutdown
 
@@ -80,7 +79,7 @@ shutdown
        event and use it to stop the service.
 
        Example: 50.samba uses this event to shut down the Samba
-       daemon if CTDB_MANAGES_SAMBA=yes.
+       daemon.
 
 monitor
 
index 4e029065ab06caa8c712016d749df9c9466a81bb..97086f78ed00b50c99ff372eca0e8fe0cc029cfb 100755 (executable)
@@ -28,8 +28,6 @@ nfs_callout_pre ()
 # shellcheck disable=SC2154
 nfs_callout_init "$script_state_dir"
 
-[ "$CTDB_MANAGES_NFS" = "yes" ] || exit 0
-
 case "$1" in
 takeip)
        nfs_callout_pre "$@"
index e073608e995e7d05e6e2bc19c4ae68e8e8dea0d1..3b19923cc1b28d796b2b318ea14286068dead31c 100755 (executable)
@@ -19,8 +19,6 @@ esac
 
 load_script_options
 
-[ "$CTDB_MANAGES_CLAMD" = "yes" ] || exit 0
-
 case "$1" in
 startup)
        service "$service_name" stop > /dev/null 2>&1
index c2e0eda5c1afa7183cb5d0d071a13a6e9cf04dc2..69876d26dacb4a2205e3376ce88275e41fdd7edd 100755 (executable)
@@ -17,8 +17,6 @@ load_script_options
 
 ctdb_setup_state_dir "service" "$service_name"
 
-[ "$CTDB_MANAGES_VSFTPD" = "yes" ] || exit 0
-
 case "$1" in
 startup)
        service "$service_name" stop > /dev/null 2>&1
index 4030d7cc3bb6eb882c49835b5dfcb360c8300795..3d67aee90285eec0108a977476ba77752223cd45 100755 (executable)
@@ -43,8 +43,6 @@ service_stop ()
     killall -q -9 $service_name || true
 }
 
-[ "$CTDB_MANAGES_HTTPD" = "yes" ] || exit 0
-
 case "$1" in
 startup)
        service_start
index 07d4c1c2b05ab58e3048b4cbcc76656515e0e3b9..8b1c8b853c0caea7e3dc43fd484f45f8158eb4cf 100755 (executable)
@@ -34,10 +34,6 @@ service_stop ()
 
 ###########################
 
-[ "$CTDB_MANAGES_WINBIND" = "yes" ] || exit 0
-
-###########################
-
 case "$1" in
 startup)
        service_start
index f65f53a15db8924348be175b12c7638ae7ee2156..ce9e05f9756f5c2f8d0fc469eabbdc87d48fb315 100755 (executable)
@@ -147,10 +147,6 @@ list_samba_ports ()
 
 ###########################
 
-[ "$CTDB_MANAGES_SAMBA" = "yes" ] || exit 0
-
-###########################
-
 case "$1" in
 startup)
        service_start
index 51d87269520c9e6e01e9db122863c4ee672578a4..2eb90b421c86d69253a115cf9a9af3c8809908dc 100755 (executable)
@@ -253,8 +253,6 @@ nfs_update_lock_info ()
 # shellcheck disable=SC2154
 nfs_callout_init "$script_state_dir"
 
-[ "$CTDB_MANAGES_NFS" = "yes" ] || exit 0
-
 case "$1" in
 startup)
        nfs_callout "$@" || exit $?
index 670e0d79e8c2f0cc021ba7987eea12ca01d04dc7..0828d473b7a9ddb053c627cf7dc7361a14e2ac3a 100755 (executable)
@@ -13,8 +13,6 @@ service_name="iscsi"
 
 load_script_options
 
-[ "$CTDB_MANAGES_ISCSI" = "yes" ] || exit 0
-
 [ -z "$CTDB_START_ISCSI_SCRIPTS" ] && {
        echo "No iscsi start script directory found"
        exit 0
index 0c280c5b926eca1c55f8ec7e87b7b782b900e770..79e82afbb6d37277268d016df587170be5ceaff8 100644 (file)
@@ -1,22 +1,16 @@
-# For now, use script.options to demonstrate these options.  The
-# CTDB_MANAGES_* variables will go away soon.  See other *.options
-# examples for more specific examples.
+# For now, use script.options to demonstrate these options.  See
+# *.options examples for more specific examples.
 
 #
 # Samba configuration
 #
 
 # 50.samba.options
-CTDB_MANAGES_SAMBA=yes
 # CTDB_SAMBA_SKIP_SHARE_CHECK=yes
 
-# 49.winbind.options
-CTDB_MANAGES_WINBIND=yes
-
 #
 # NFS configuration
 #
 
 # 60.nfs.options
-CTDB_MANAGES_NFS=yes
 CTDB_RPCINFO_LOCALHOST="127.0.0.1"
index 22c5aa03c5b0ec5455063df124e0b7264e0f5364..be8d4f4ce5a7f108797082eaea57e490dca5127a 100644 (file)
@@ -563,20 +563,6 @@ CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=9000
 
       <variablelist>
 
-       <varlistentry>
-         <term>
-           CTDB_MANAGES_CLAMD=yes|no
-         </term>
-         <listitem>
-           <para>
-             Should CTDB manage ClamAV?
-           </para>
-           <para>
-             Default is no.
-           </para>
-         </listitem>
-       </varlistentry>
-
        <varlistentry>
          <term>
            CTDB_CLAMD_SOCKET=<parameter>FILENAME</parameter>
@@ -595,52 +581,6 @@ CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=9000
 
     </refsect2>
 
-    <refsect2>
-      <title>40.vsftpd</title>
-
-      <para>
-       Provides CTDB's vsftpd FTP service management.
-      </para>
-
-      <variablelist>
-       <varlistentry>
-         <term>CTDB_MANAGES_VSFTPD=yes|no</term>
-         <listitem>
-           <para>
-             Should CTDB manage the vsftpd FTP server?
-           </para>
-           <para>
-             Default is no.
-           </para>
-         </listitem>
-       </varlistentry>
-      </variablelist>
-    </refsect2>
-
-    <refsect2>
-      <title>41.httpd</title>
-
-      <para>
-       Provides CTDB's Apache web service management.
-      </para>
-
-      <variablelist>
-       <varlistentry>
-         <term>
-           CTDB_MANAGES_HTTPD=yes|no
-         </term>
-         <listitem>
-           <para>
-             Should CTDB manage the Apache web server?
-           </para>
-           <para>
-             Default is no.
-           </para>
-         </listitem>
-       </varlistentry>
-      </variablelist>
-    </refsect2>
-
     <refsect2>
       <title>49.winbind</title>
 
@@ -650,20 +590,6 @@ CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=9000
 
       <variablelist>
 
-       <varlistentry>
-         <term>
-           CTDB_MANAGES_WINBIND=yes|no
-         </term>
-         <listitem>
-           <para>
-             Should CTDB manage Winbind?
-           </para>
-           <para>
-             Default is no.
-           </para>
-         </listitem>
-       </varlistentry>
-
        <varlistentry>
          <term>
            CTDB_SERVICE_WINBIND=<parameter>SERVICE</parameter>
@@ -691,20 +617,6 @@ CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=9000
 
       <variablelist>
 
-       <varlistentry>
-         <term>
-           CTDB_MANAGES_SAMBA=yes|no
-         </term>
-         <listitem>
-           <para>
-             Should CTDB manage Samba?
-           </para>
-           <para>
-             Default is no.
-           </para>
-         </listitem>
-       </varlistentry>
-
        <varlistentry>
          <term>
            CTDB_SAMBA_CHECK_PORTS=<parameter>PORT-LIST</parameter>
@@ -785,20 +697,6 @@ CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=9000
 
       <variablelist>
 
-       <varlistentry>
-         <term>
-           CTDB_MANAGES_NFS=yes|no
-         </term>
-         <listitem>
-           <para>
-             Should CTDB manage NFS?
-           </para>
-           <para>
-             Default is no.
-           </para>
-         </listitem>
-       </varlistentry>
-
        <varlistentry>
          <term>
            CTDB_NFS_CALLOUT=<parameter>COMMAND</parameter>
@@ -936,20 +834,6 @@ CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=9000
 
       <variablelist>
 
-       <varlistentry>
-         <term>
-           CTDB_MANAGES_ISCSI=yes|no
-         </term>
-         <listitem>
-           <para>
-             Should CTDB manage iSCSI tgtd?
-           </para>
-           <para>
-             Default is no.
-           </para>
-         </listitem>
-       </varlistentry>
-
        <varlistentry>
          <term>
            CTDB_START_ISCSI_SCRIPTS=<parameter>DIRECTORY</parameter>