[Piuparts-commits] [SCM] piuparts git repository branch, develop, updated. 0.50-90-g8664feb

Andreas Beckmann anbe at debian.org
Sat Apr 13 14:09:39 UTC 2013


The following commit has been merged in the develop branch:
commit 5f5547c5ce9143326c1d47c8a6862f5fc4f670aa
Author: Andreas Beckmann <anbe at debian.org>
Date:   Mon Apr 8 02:41:12 2013 +0200

    p-s/p-m: document the new "section" command
    
    master: this will allow restricting the ssh key from the slave
    to run a fixed command that does not take arguments
    
    Signed-off-by: Andreas Beckmann <anbe at debian.org>

diff --git a/README.txt b/README.txt
index b7d060b..9a86b30 100644
--- a/README.txt
+++ b/README.txt
@@ -329,6 +329,8 @@ the master responds with):
 
 ----
 << hello
+>> section sid
+<< ok
 >> pass liwc 1.2.3-4
 >>  The piuparts
 >>  log file comes
@@ -350,6 +352,20 @@ The slave shall not speak until the master has spoken.
 Commands and responses in this protocol:
 
 ----
+Command: section <string>
+Success: ok
+Failure: error
+Failure: busy
+----
+Slave asks master to select the given section.
+This must be the very first command sent by the slave, but may
+be repeated later on to switch between sections.
+It will return "error" if the section is unknown and "busy" if
+it is currently processed by another master instance. If the
+section command fails, no other commands than "section" will be
+allowed until one succeeds.
+
+----
 Command: recycle
 Success: ok
 Failure: error
@@ -518,8 +534,6 @@ section, too, and will serve as defaults for all other sections
 * "master-command" is the command to run on master-host to start
  the master. When the master has been installed from the Debian
  package, the command is '/usr/share/piuparts/piuparts-master'.
- The section name will be given as a command line argument to this
- command.
 
 * "idle-sleep" is the length of time the slave should wait before
  querying the master again if the master didn't have any new
diff --git a/debian/changelog b/debian/changelog
index 69ba842..ae8cd1e 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -19,10 +19,17 @@ piuparts (0.51) UNRELEASED; urgency=low
       logging. No longer uses the section specific logfile name for errors.
   * piuparts-master-backend.py:
     - Raise CommandSyntaxError on unknown commands.
+    - Add "section" command:
+      + Make section selection part of the master-slave protocol.
+      + Allow switching sections without reconnecting.
+      + No longer accept section argument on the command line.
+      + Switch the logfile after switching sections.
   * piuparts-slave.py:
     - Fix parsing 'idle' return value from master.
     - Let the piuparts-master (wrapper script) handle chdir and error logging.
     - Skip sections that don't exist in piuparts.conf and continue to run.
+    - Pass the section to piuparts-master via the new "section" command
+      instead of using a command line argument.
   * piuparts-analyze.py:
   * piuparts-report.py:
     - Skip sections that don't exist in piuparts.conf.
diff --git a/piuparts-master.in b/piuparts-master.in
index bd1c4ea..f269ac3 100755
--- a/piuparts-master.in
+++ b/piuparts-master.in
@@ -33,6 +33,7 @@ get_config_value LOGFILE global log-file master-error.log
 export PYTHONPATH
 LOGFILE="$LOGFILE.$$"
 
+# put logfile in a deterministic location
 cd "$MASTER"
 
 trap "test -s ${LOGFILE} || rm -f ${LOGFILE}" EXIT

-- 
piuparts git repository



More information about the Piuparts-commits mailing list