[Piuparts-commits] [SCM] piuparts git repository branch, master, updated. 0.51
Andreas Beckmann
anbe at debian.org
Wed May 15 10:09:30 UTC 2013
The following commit has been merged in the master branch:
commit 54f3a00f308338b6177ec294b5cb8de45ad9df26
Author: Andreas Beckmann <anbe at debian.org>
Date: Fri Mar 8 23:45:26 2013 +0100
p-m: add new wrapper script piuparts-master
realize this as a shell script that reads piuparts.conf to
get paths and avoid having the slave needing to know these
Signed-off-by: Andreas Beckmann <anbe at debian.org>
diff --git a/Makefile b/Makefile
index 53829f6..4fbcb8c 100644
--- a/Makefile
+++ b/Makefile
@@ -20,7 +20,7 @@ endif
# generate several scripts, conffiles, ... from templates (*.in, *.py)
# by substituting placeholders
-SCRIPTS_TEMPLATES = $(wildcard master-bin/*.in slave-bin/*.in conf/*.in)
+SCRIPTS_TEMPLATES = $(wildcard *.in master-bin/*.in slave-bin/*.in conf/*.in)
SCRIPTS_PYTHON_BINARY = $(wildcard *.py)
SCRIPTS_GENERATED = $(SCRIPTS_TEMPLATES:.in=) $(SCRIPTS_PYTHON_BINARY:.py=)
DOCS_GENERATED = piuparts.1 piuparts.1.html README.html
@@ -101,7 +101,7 @@ install: build-stamp
install -m 0755 piuparts $(DESTDIR)$(sbindir)/
install -d $(DESTDIR)$(sharedir)/piuparts
- install -m 0755 piuparts-slave piuparts-master-backend piuparts-report piuparts-analyze $(DESTDIR)$(sharedir)/piuparts/
+ install -m 0755 piuparts-slave piuparts-master piuparts-master-backend piuparts-report piuparts-analyze $(DESTDIR)$(sharedir)/piuparts/
install -d $(DESTDIR)$(site26)/piupartslib
install -d $(DESTDIR)$(site27)/piupartslib
diff --git a/debian/changelog b/debian/changelog
index b7d17d1..e769dac 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,8 @@ piuparts (0.51) UNRELEASED; urgency=low
* distros.conf:
* piupartslib/packagesdb.py:
* Rename piuparts-master.py to piuparts-master-backend.py
+ * piuparts-master: New.
+ - Wrapper shell script to simplify calling the master from the slave.
* piuparts-master-backend.py:
* piuparts-slave.py:
* piuparts-analyze.py:
diff --git a/debian/piuparts-master.install b/debian/piuparts-master.install
index 1342e9e..be3daca 100644
--- a/debian/piuparts-master.install
+++ b/debian/piuparts-master.install
@@ -5,5 +5,6 @@ usr/share/piuparts/htdocs/*
usr/share/piuparts/master/*
usr/share/piuparts/known_problems/*
usr/share/piuparts/piuparts-analyze
+usr/share/piuparts/piuparts-master
usr/share/piuparts/piuparts-master-backend
usr/share/piuparts/piuparts-report
diff --git a/master-bin/master_cleanup.in b/piuparts-master.in
similarity index 66%
copy from master-bin/master_cleanup.in
copy to piuparts-master.in
index eb89229..358ed18 100755
--- a/master-bin/master_cleanup.in
+++ b/piuparts-master.in
@@ -1,7 +1,7 @@
#!/bin/sh
set -e
-# Copyright © 2012 Andreas Beckmann <debian at abeckmann.de>
+# Copyright © 2013 Andreas Beckmann <anbe at debian.org>
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
@@ -18,22 +18,22 @@ set -e
# 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
-# cleanup $HTDOCS/daily.lock
-#
-# - this should only be run (automatically) on boot
+# wrapper for running piuparts-master-backend without needing to know
+# anything about the master setup and paths
#
. @sharedir@/piuparts/lib/read_config.sh
-get_config_value HTDOCS global output-directory
+get_config_value PYTHONPATH global PYTHONPATH ''
+
+export PYTHONPATH
-LOCKFILE=$HTDOCS/daily.lock
-if [ -e $LOCKFILE ]; then
- if pgrep -f generate_daily_report || pgrep -f piuparts-report ; then
- echo "daily processing is running"
- else
- rm -f -v $LOCKFILE
- fi
+section="$1"
+if [ -z "$section" ]; then
+ echo "FAIL: no section supplied"
+ exit 1
fi
+
+ at sharedir@/piuparts/piuparts-master-backend "$section"
--
piuparts git repository
More information about the Piuparts-commits
mailing list