Browse Source

Add support for /etc/popularity-contest.d

tags/popcon-1.61
Bill Allombert 7 years ago
parent
commit
bdd8435c14
3 changed files with 38 additions and 4 deletions
  1. +20
    -0
      FAQ
  2. +9
    -2
      debian/changelog
  3. +9
    -2
      debian/cron.daily

+ 20
- 0
FAQ View File

@@ -116,3 +116,23 @@ date with

date -d '@1139229934'

====== FAQ For derivative distribution ======

Q) How can I set up popularity-contest to report to my own server
in addition to Debian ?

A) You need to provide a keyring file with the public key used by your server,
then you can add a file matching /etc/popularity-contest.d/*.conf with
KEYRING="$KEYRING --keyring /path/to/your/keyring"
POPCONKEY="$POPCONKEY -r YOURKEYID"
SUBMITURLS="$SUBMITURLS http://myserver/popcon.cgi"
MAILTO="$MAILTO, survey@myserver" # Optional

Q) And if I do not want to report to Debian, but I do not want to change
/etc/popularity-contest.conf ?

A) Add a file matching /etc/popularity-contest.d/00*.conf with
KEYRING="/path/to/your/keyring"
POPCONKEY="YOURKEYID"
SUBMITURLS="http://myserver/popcon.cgi"
MAILTO="survey@myserver" # or MAILTO=""

+ 9
- 2
debian/changelog View File

@@ -12,8 +12,15 @@ popularity-contest (1.61) unstable; urgency=low
- Updated Standards-Version from 3.9.4 to 3.9.5. No change needed.
- Add Vcs-Browser and Vcs-Git fields. Closes: 729024.
Thanks Yaroslav Halchenko.

-- Bill Allombert <ballombe@debian.org> Mon, 24 Feb 2014 22:56:49 +0100
* Allow derivatives to set up their own public keys in addition to Debian.
Closes: 729097. Thanks Yaroslav Halchenko.
+ debian/cron.daily:
- Add support for /etc/popularity-contest.d/
- Allow multiple keyrings and keys to be set.
+ FAQ: Add section for derivative distributions
- Document /etc/popularity-contest.d/

-- Bill Allombert <ballombe@debian.org> Wed, 26 Feb 2014 12:18:41 +0100

popularity-contest (1.60) unstable; urgency=low



+ 9
- 2
debian/cron.daily View File

@@ -18,6 +18,13 @@ unset MTAOPS
. /usr/share/popularity-contest/default.conf
. /etc/popularity-contest.conf

if test -d /etc/popularity-contest.d/; then
for file in `run-parts --list --regex '\.conf$' /etc/popularity-contest.d/`;
do
. $file
done
fi

# don't run if MAILTO address is blank, and not configured to use HTTP POST!
if [ -z "$MAILTO" ] && [ "yes" != "$USEHTTP" ]; then exit 0; fi

@@ -80,8 +87,8 @@ if [ -x "$GPG" ] && [ "$ENCRYPT" = "maybe" ] || [ "$ENCRYPT" = "yes" ]; then
rm -f "$POPCONGPG"
GPGHOME=`mktemp -d`
$GPG --batch --no-options --no-default-keyring --trust-model=always \
--homedir "$GPGHOME" --keyring "$KEYRING" --quiet \
--armor -o "$POPCONGPG" -r "$POPCONKEY" --encrypt "$POPCON"
--homedir "$GPGHOME" --keyring $KEYRING --quiet \
--armor -o "$POPCONGPG" -r $POPCONKEY --encrypt "$POPCON"
rm -rf "$GPGHOME"
POPCON="$POPCONGPG"
fi


Loading…
Cancel
Save