Skip to Content.
Sympa Menu

perfsonar-dev - [pS-dev] [GEANT/SA2/SA2T3-OPPD] r866 - in trunk: contrib/debian etc/oppd.d.example perfsonar-oppd/build/debian/scripts perfsonar-oppd-mp-bwctl/build perfsonar-oppd-mp-bwctl/build/debian/scripts

Subject: perfsonar development work

List archive

[pS-dev] [GEANT/SA2/SA2T3-OPPD] r866 - in trunk: contrib/debian etc/oppd.d.example perfsonar-oppd/build/debian/scripts perfsonar-oppd-mp-bwctl/build perfsonar-oppd-mp-bwctl/build/debian/scripts


Chronological Thread 
  • From:
  • To:
  • Subject: [pS-dev] [GEANT/SA2/SA2T3-OPPD] r866 - in trunk: contrib/debian etc/oppd.d.example perfsonar-oppd/build/debian/scripts perfsonar-oppd-mp-bwctl/build perfsonar-oppd-mp-bwctl/build/debian/scripts
  • Date: Wed, 12 Mar 2014 22:16:00 +0000 (GMT)

Author: dfn.calim
Date: 2014-03-12 22:16:00 +0000 (Wed, 12 Mar 2014)
New Revision: 866

Added:
trunk/perfsonar-oppd/build/debian/scripts/postrm
trunk/perfsonar-oppd/build/debian/scripts/preinst
Removed:
trunk/contrib/debian/oppd.default
trunk/etc/oppd.d.example/bwctl.conf
Modified:
trunk/perfsonar-oppd-mp-bwctl/build/Build.PL
trunk/perfsonar-oppd-mp-bwctl/build/debian/scripts/control
Log:
moving scripts to other packages

Deleted: trunk/contrib/debian/oppd.default
===================================================================
--- trunk/contrib/debian/oppd.default 2014-03-11 20:34:59 UTC (rev 865)
+++ trunk/contrib/debian/oppd.default 2014-03-12 22:16:00 UTC (rev 866)
@@ -1,40 +0,0 @@
-# Path to oppd.
-#DAEMON=/usr/bin/oppd.pl
-
-# Configuration file to be used by oppd.
-#CONFFILE=/etc/oppd.conf
-
-# pid file to use. The init script overwrites the pid file used (from
-# configuration file or default) to make sure that the init script can
control
-# the daemon via the pid file. Therefore you can change the pid file ONLY
here!
-#PIDFILE=/var/run/oppd.pid
-
-# log file to use. If you set a log file here, it will not only be set as the
-# log file used by the daemon (overriding value from configuration file). The
-# daemon will also care about the ownership of the file based on the
variables
-# DAEMONUSER and DAEMONGROUP you can find below.
-#LOGFILE=""
-
-# User to run the daemon as. Files (especially the pid file and log file, see
-# above) created by the daemon will be owned by this user.
-#DAEMONUSER=perfsonar
-
-# Group id used for pid file and log file (see above).
-#DAEMONGROUP=perfsonar
-
-# Additional command line arguments (overriding options from configuration
-# file!).
-#DAEMON_ARGS=""
-
-# Time to wait for the daemon to die, in seconds. If this value is set too
low
-# you might not let the daemon die gracefully and 'restart' may not work.
-#DIETIME=30
-
-# Time to wait for the daemon to start, in seconds. If this value is set each
-# time the daemon is started (on start or restart) the script will stall to
try
-# to determine if it is running. If it is not set and the server takes time
-# to setup a pid file the log message might be a false positive (says it did
-# not start when it actually did)
-# Example: STARTTIME=2
-#STARTTIME=""
-

Deleted: trunk/etc/oppd.d.example/bwctl.conf
===================================================================
--- trunk/etc/oppd.d.example/bwctl.conf 2014-03-11 20:34:59 UTC (rev 865)
+++ trunk/etc/oppd.d.example/bwctl.conf 2014-03-12 22:16:00 UTC (rev 866)
@@ -1,84 +0,0 @@
-#
-# BWCTL MP example configuration
-#
-
-<service MP/BWCTL>
-
- #
- # Necessary parameters for module initialisation
- #
- module MP::BWCTL # Name of module to load
- servicetype MP # Service type: MP or MA
-
- #
- # Module parameters
- #
- <module_param>
-
- ##################################
- #### BEGIN LS INFORMATION ####
- #### This fields will be sent ####
- #### to Lookup Service server ####
- ##################################
- <ls_param>
- # Mandatory fields:
- #ServiceName: can be freely chosen
- ServiceName "BWCTL Measurement Point"
-
- #Access point: the URL at which the service is available
- # This is set by the service itself
-
- #Service type in this case BWCTL_MP
- ServiceType "BWCTL_MP"
-
- # Organization/Domain set it to the used domain for example GEANT
- Organization "GEANT"
-
- #
- # Optional fields:
- #
- # Service description: can be freely chosen
- ServiceDescription "Measurement Point for doing on-demand BWCTL tests"
-
- #Service version
- # This is done by the service itself
-
- # Contact email: can be freely chosen
- ContactEmail
""
-
- # keyword: describe service by keywords
- keyword "project:mybwctl"
-
- # Measurement metric(s). More than one element definition possible.
- metric "bandwidth"
-
- </ls_param>
- ################################
- #### END LS INFORMATION ####
- ################################
-
- # tool which tool is used from this service
- tool "bwctl"
-
- # Command to execute e.g. "/usr/bin/bwctl" or "/bin/bwctl".
- # Omitting path searches $PATH.
- command "bwctl"
-
-
- # service
- # This is to get different service setting
- # For example eventtpye
- service "bwctl"
-
- #
- # Store functionality
- #
- # store: Enable/disable store functionality
- store off
-
- # URL of a MA service to sent the results of measurements to
- store_url "http://www.mySQL-MA:8090";
-
- </module_param>
-
-</service MP/BWCTL>

Added: trunk/perfsonar-oppd/build/debian/scripts/postrm
===================================================================
--- trunk/perfsonar-oppd/build/debian/scripts/postrm
(rev 0)
+++ trunk/perfsonar-oppd/build/debian/scripts/postrm 2014-03-12 22:16:00
UTC (rev 866)
@@ -0,0 +1,50 @@
+#!/bin/sh
+# postrm script for perfsonar-oppd
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+# * <postrm> `remove'
+# * <postrm> `purge'
+# * <old-postrm> `upgrade' <new-version>
+# * <new-postrm> `failed-upgrade' <old-version>
+# * <new-postrm> `abort-install'
+# * <new-postrm> `abort-install' <old-version>
+# * <new-postrm> `abort-upgrade' <old-version>
+# * <disappearer's-postrm> `disappear' <overwriter>
+# <overwriter-version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+case "$1" in
+ remove|disappear)
+ rm /var/log/oppd.log
+ /usr/sbin/userdel perfsonar
+ #/usr/sbin/groupdel perfsonar
+ ;;
+
+ purge|abort-install)
+ ;;
+
+ upgrade)
+ ;;
+
+ failed-upgrade|abort-upgrade)
+ ;;
+
+ *)
+ echo "postrm called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
+
+

Added: trunk/perfsonar-oppd/build/debian/scripts/preinst
===================================================================
--- trunk/perfsonar-oppd/build/debian/scripts/preinst
(rev 0)
+++ trunk/perfsonar-oppd/build/debian/scripts/preinst 2014-03-12 22:16:00
UTC (rev 866)
@@ -0,0 +1,89 @@
+#!/bin/sh
+# preinst script for perfsonar-oppd
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+# * <new-preinst> `install'
+# * <new-preinst> `install' <old-version>
+# * <new-preinst> `upgrade' <old-version>
+# * <old-preinst> `abort-upgrade' <new-version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+[ -f "/etc/default/oppd" ] && . /etc/default/oppd
+
+# most of the contents are copied from
+# http://www.debian.org/doc/manuals/securing-debian-howto/ch9.en.html
+
+case "$1" in
+ install|upgrade)
+ [ -z "$SERVER_USER" ] && SERVER_USER=perfsonar
+ [ -z "$SERVER_NAME" ] && SERVER_NAME="Open Perl perfSONAR Daemon"
+ [ -z "$SERVER_GROUP" ] && SERVER_GROUP=perfsonar
+ [ -z "$SERVER_LOGFILE" ] && SERVER_LOGFILE=/var/log/oppd.log
+
+ # create group if not existing
+ if ! getent group | grep -q "^$SERVER_GROUP:" ; then
+ echo -n "Adding group $SERVER_GROUP.."
+ addgroup --quiet --system $SERVER_GROUP 2>/dev/null ||true
+ echo "..done"
+ fi
+ # create user if not existing
+ if ! getent passwd | grep -q "^$SERVER_USER:"; then
+ echo -n "Adding system user $SERVER_USER.."
+ adduser --quiet \
+ --system \
+ --ingroup $SERVER_GROUP \
+ --no-create-home \
+ --disabled-password \
+ $SERVER_USER 2>/dev/null || true
+ echo "..done"
+ fi
+ #adjust passwd entry
+ usermod -c "$SERVER_NAME" \
+ -g $SERVER_GROUP \
+ $SERVER_USER
+ # adjust file and directory permissions
+ #Check if directory exist
+ if [ ! -e $SERVER_LOGFILE ];
+ then
+ echo -n "Creating log file for oppd"
+ touch $SERVER_LOGFILE
+ chown $SERVER_GROUP:$SERVER_USER $SERVER_LOGFILE
+ echo "...done"
+ fi
+ ;;
+ configure)
+ ;;
+
+ supgrade)
+ #Check if oppd is running. If running stop it first
+ #if ps ax | grep -v grep | grep oppd > /dev/null; then
+ #if which invoke-rc.d >/dev/null 2>&1; then
+ # invoke-rc.d oppd stop
+ #else
+ # /etc/init.d/oppd stop
+ #fi
+ #fi
+ ;;
+
+ abort-upgrade)
+ ;;
+
+ *)
+ echo "preinst called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
+
+

Modified: trunk/perfsonar-oppd-mp-bwctl/build/Build.PL
===================================================================
--- trunk/perfsonar-oppd-mp-bwctl/build/Build.PL 2014-03-11 20:34:59
UTC (rev 865)
+++ trunk/perfsonar-oppd-mp-bwctl/build/Build.PL 2014-03-12 22:16:00
UTC (rev 866)
@@ -19,7 +19,10 @@
'etc/bwctl.conf' => 'etc/oppd.d/bwctl.conf',
},
add_to_cleanup => [ 'perfSONAR-*' ],
- create_makefile_pl => 'small',
+ #create_makefile_pl => 'small',
);
-$builder->install_base_relpaths('etc' => 'etc');
+
+$builder->install_path( 'etc' => '/etc');
+$builder->add_build_element('etc');
+
$builder->create_build_script();

Modified: trunk/perfsonar-oppd-mp-bwctl/build/debian/scripts/control
===================================================================
--- trunk/perfsonar-oppd-mp-bwctl/build/debian/scripts/control 2014-03-11
20:34:59 UTC (rev 865)
+++ trunk/perfsonar-oppd-mp-bwctl/build/debian/scripts/control 2014-03-12
22:16:00 UTC (rev 866)
@@ -8,7 +8,7 @@

Package: perfsonar-oppd-mp-bwctl
Architecture: all
-Depends: ${shlibs:Depends}, ${misc:Depends}, perfsonar-oppd (>= 1.0),
+Depends: ${shlibs:Depends}, ${misc:Depends}, perfsonar-oppd (>=
1.0),libperfsonar-mp-bwctl-perl (>=1.0),
Description: The perfsonar oppd BWCTL MP service.
The README is used to introduce the module and provide instructions on how
to install the module, any machine dependencies it may have (for example C



  • [pS-dev] [GEANT/SA2/SA2T3-OPPD] r866 - in trunk: contrib/debian etc/oppd.d.example perfsonar-oppd/build/debian/scripts perfsonar-oppd-mp-bwctl/build perfsonar-oppd-mp-bwctl/build/debian/scripts, svn-noreply, 03/12/2014

Archive powered by MHonArc 2.6.16.

Top of Page