Package: nstx
Version: 1.1-beta6-4
Severity: wishlist
Tags: patch

I don't need nstxcd to run all the time.  In particular, it doesn't need 
to start at boot time.  However, I'd like to be able to use the normal 
start up mechanism to start it on demand from the command line by, e.g., 
running the following:

  /etc/init.d/nstxcd start

Taking inspiration form openvpn, which allows you to start arbitary 
interfaces using the form:

  /etc/init.d/openvpn start vpn-name

I'd propose that /etc/init.d nstxcd take an additional argument, force, 
which indicates whether to respect the start_nstxcd variable.


-- System Information:
Debian Release: 4.0
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-4-686
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) (ignored: LC_ALL 
set to en_US.UTF-8)

Versions of packages nstx depends on:
ii  adduser                     3.102        Add and remove users and groups
ii  libc6                       2.3.6.ds1-13 GNU C Library: Shared libraries

nstx recommends no packages.

-- no debconf information
--- nstxcd.orig 2007-06-12 10:51:05.000000000 +0200
+++ nstxcd      2007-06-12 10:48:09.000000000 +0200
@@ -16,9 +16,16 @@ fi
 
 set -e
 
+FORCE=$2
+
 check_start_nstxcd_option() {
+    # Force it to start.
+    if [ "x$FORCE" = "xforce" ]; then
+        return 0
+    fi
+
     if [ ! "$start_nstxcd" = "yes" ]; then
-       echo "Not starting nstx client, disabled via /etc/default/nstx"
+       echo "Not starting, disabled via /etc/default/nstx; try $0 start force"
        return 1
     else
        return 0

Reply via email to