Browse Source

Add support for reporting to several URLs, to ease debugging and increase flexibility.

suites/ascii
Petter Reinholdtsen 17 years ago
parent
commit
fea194c4ae
  1. 3
      debian/changelog
  2. 10
      debian/cron.weekly
  3. 5
      default.conf

3
debian/changelog

@ -1,6 +1,7 @@
popularity-contest (1.30) UNRELEASED; urgency=low
* Add support for reporting using http POST. (Closes: #239097)
* Add support for reporting using http POST to a list of
URLs. (Closes: #239097)
* New script /usr/share/popularity-contest/popcon-upload
* New CGI /usr/share/doc/popularity-contest/popcon.cgi
* Uploading using content-type text/plain, content-encoding x-gzip.

10
debian/cron.weekly

@ -9,7 +9,7 @@ unset MAILFROM
unset MAILTO
unset MY_HOSTID
unset PARTICIPATE
unset SUBMITURL
unset SUBMITURLS
unset USEHTTP
# get configuration information
@ -50,13 +50,15 @@ run_popcon > $POPCON
SUBMITTED=no
# try to post the report through http POST
if [ "$SUBMITURL" ] && [ "yes" = "$USEHTTP" ]; then
if [ "$SUBMITURLS" ] && [ "yes" = "$USEHTTP" ]; then
for URL in $SUBMITURLS ; do
if setsid /usr/share/popularity-contest/popcon-upload \
-u $SUBMITURL -f $POPCON 2>/dev/null ; then
-u $URL -f $POPCON 2>/dev/null ; then
SUBMITTED=yes
else
logger -t popularity-contest "unable to submit report using http."
logger -t popularity-contest "unable to submit report to $URL."
fi
done
fi
# try to email the popularity contest data

5
default.conf

@ -28,8 +28,9 @@ MAILTO="survey@popcon.debian.org"
#
#MAILFROM="root@example.org"
# SUBMITURL is where to submit popularity-contest reports using http.
SUBMITURL=http://popcon.debian.org/cgi-bin/popcon.cgi
# SUBMITURLS is a space separated list of where to submit
# popularity-contest reports using http.
SUBMITURLS="http://popcon.debian.org/cgi-bin/popcon.cgi"
# USEHTTP enables http reporting. Set this to 'yes' to enable it.
USEHTTP="no"

Loading…
Cancel
Save