diff --git a/FAQ b/FAQ index 12a1b4e..2243f40 100644 --- a/FAQ +++ b/FAQ @@ -1,5 +1,5 @@ ,------------------------------------------------------------------------------- -| Frequently asked0 questions about metche +| Frequently asked questions about metche `------------------------------------------------------------------------------- 1. How are the monitored Changelog files ($CHANGELOG_FILE or @@ -59,8 +59,8 @@ STABLE_TIME configuration values (the "for a while" meaning depends on how much nervous you get when you run 'df /var' every five minute; a few days is a bare minimum, a few weeks is better). - - Then, have a look to the files metche has kept in $BACKUP_DIR; a simple - 'metche list' is enough if you're not monitoring any VServer. + - Then, have a look to the files metche has kept in $BACKUP_DIR; a + simple 'metche list' is enough if you're not monitoring any VServer. - If there is a huge list of "unstable" but only few "testing" states, you can try lowering TESTING_TIME. If there are many more "testing" states than "stable" state, you can try lowering STABLE_TIME. @@ -72,7 +72,8 @@ metche does not handle well, call it a bug or whatever you want; you should actually e-mail us (metche AT lists DOT riseup DOT net) the output of 'metche list', your configuration file (stripped from private - information), and some information about the metche version you're running. + information), and some information about the metche version you're + running. 7. metche does not send us any report diff --git a/README b/README index f01ad7d..c314672 100644 --- a/README +++ b/README @@ -102,10 +102,10 @@ - the "system state" backups will be saved in sub-directory in BACKUP_DIR's, called the same as the VServer; - EMAIL_ADDRESS is not used for the VServers: the report messages will be - sent to the your VServer's root email address; if you're using - ENCRYPT_EMAIL to encrypt the report messages, make sure their public key is - in the host system root's keyring, trusted enough to be used blindly by - metche; + sent to the root email address of the VServer; if you're using + ENCRYPT_EMAIL to encrypt the report messages, make sure the relevant + public key are in the host system root's keyring, trusted enough to be + used blindly by metche; - all other configuration variables are used as it. Most of metche commands (namely: list, report and stabilize) support a diff --git a/debian/changelog b/debian/changelog index e0d1f8e..58fa8f8 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,9 +1,33 @@ -metche (1.0-2) unstable; urgency=low +metche (1:1.1-1) unstable; urgency=low + + * New upstream release, including these fixes: + - add support for Linux VServers, + - improve default EXCLUDES, + - clear up documentation about how backups are mode, (Closes: #365694) + * Add Suggests for util-vserver. + * Bump Standards-version to 3.7.2 (no changes required). + * Add translations for debconf templates in: + - french, thanks to Cyril Brulebois, (Closes: #364967) + - czech, thanks to Martin Šín. (Closes: #382922) + * Change debconf default settings to be coherent with upstream default + configuration file. + * Switch to ucf for configuration handling. (Closes: #367545) + * Various other fixes in postinst and config script. + * Add a postrm script to purge the package correctly: + - configuration files: /etc/metche.conf, /etc/cron.d/metche + - /!\ data files: /var/lib/metche /!\ + * Move debhelper and add po-debconf to Build-Depends (used in the clean rule). + * Add myself as an uploader. + + -- Jérémy Bobbio Sat, 16 Sep 2006 18:35:06 +0200 + +metche (1:1.0-2) unstable; urgency=low * Using gettext-based debconf templates (Closes: #359252) * Added debconf-updatepo to clean target of debian/rules to ensure that debconf template files are changed so translators can be warned their files are outdated. + * Added epoch to version number due to erroneous backports upload -- Micah Anderson Tue, 4 Apr 2006 22:28:47 +0200 diff --git a/debian/config b/debian/config index f1eed50..b90cdf5 100644 --- a/debian/config +++ b/debian/config @@ -1,34 +1,37 @@ #!/bin/sh -CONFIGFILE=/etc/metche.conf set -e + . /usr/share/debconf/confmodule -if [ -e $CONFIGFILE ]; then - . $CONFIGFILE || true - db_set metche/email $EMAIL_ADDRESS +CONFIGFILE="/etc/metche.conf" + +if [ -e "$CONFIGFILE" ]; then + . "$CONFIGFILE" || true + db_set metche/email "$EMAIL_ADDRESS" db_set metche/changelog/type "No changelog monitoring" - if [ "$CHANGELOG_FILE" ]; then + if [ -n "$CHANGELOG_DIR" ]; then + db_set metche/changelog/type "Multiple changelog files" + db_set metche/changelog/directory "$CHANGELOG_DIR" + elif [ -n "$CHANGELOG_FILE" ]; then db_set metche/changelog/type "Single changelog file" - db_set metche/changelog/file $CHANGELOG_FILE - fi - if [ "$CHANGELOG_DIR" ]; then - db_set metche/changelog/type "Multiple changelog files" - db_set metche/changelog/directory $CHANGELOG_DIR + db_set metche/changelog/file "$CHANGELOG_FILE" fi fi db_input medium metche/email || true db_input medium metche/changelog/type || true db_go || true + db_get metche/changelog/type case "$RET" in -"Single changelog file") + "Single changelog file") db_input medium metche/changelog/file || true db_go || true - ;; -"Multiple changelog files") + ;; + "Multiple changelog files") db_input medium metche/changelog/directory || true db_go || true - ;; + ;; esac + diff --git a/debian/control b/debian/control index 0624ba1..b3312b8 100644 --- a/debian/control +++ b/debian/control @@ -2,21 +2,22 @@ Section: admin Priority: optional Maintainer: boum.org collective -Uploaders: Micah Anderson -Build-Depends-Indep: debhelper (>= 4.1.16) -Standards-Version: 3.6.2 +Uploaders: Micah Anderson , Jérémy Bobbio +Build-Depends: debhelper (>= 4.1.16), po-debconf +Standards-Version: 3.7.2 Package: metche Architecture: all -Depends: debconf (>= 0.5.00) | debconf-2.0, mutt, bzip2 +Depends: debconf (>= 0.5.00) | debconf-2.0, mutt, bzip2, ucf (>= 0.28) Recommends: apt-show-versions, gnupg +Suggests: util-vserver Description: configuration monitor to ease collective administration metche monitors changes made to a "system state" composed of: - a "watched" directory (typically: /etc) - - changelogs written by you in one or several files + - one or more user maintained changelog files (e.g. /root/Changelog) - - States and versions of Debian packages (using apt-show-versions) + - the state of Debian packages and versions (using apt-show-versions) by periodically: - saving backups of the corresponding files - - emailing the changes in the system state to your administrator's + - emailing the changes in the system state to your administrators' mailing list diff --git a/debian/docs b/debian/docs index e845566..888d4e2 100644 --- a/debian/docs +++ b/debian/docs @@ -1 +1,3 @@ README +FAQ +NEWS diff --git a/debian/examples b/debian/examples new file mode 100644 index 0000000..6ed023a --- /dev/null +++ b/debian/examples @@ -0,0 +1 @@ +metche.conf.default diff --git a/debian/po/cs.po b/debian/po/cs.po new file mode 100644 index 0000000..617af0f --- /dev/null +++ b/debian/po/cs.po @@ -0,0 +1,153 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# Martin Sin , 2006. +# +msgid "" +msgstr "" +"Project-Id-Version: metche 1:1.0-2\n" +"Report-Msgid-Bugs-To: metche@lists.riseup.net\n" +"POT-Creation-Date: 2006-09-16 17:02+0200\n" +"PO-Revision-Date: 2006-08-13 16:04+0200\n" +"Last-Translator: Martin Sin \n" +"Language-Team: Czech \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=utf-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: string +#. Description +#: ../templates:1001 +msgid "E-mail address receiving metche reports:" +msgstr "Emailová adresa, na kterou budou posílány zprávy metche:" + +#. Type: string +#. Description +#: ../templates:1001 +msgid "" +"metche monitors \"system state\" changes. An hour after the last change has " +"been recorded an e-mail report is sent describing changes made to:\n" +" - files inside the watched directory (/etc by default),\n" +" - user maintainted changelog file(s) (if configured to do so),\n" +" - the list of installed Debian packages (if configured to do so)." +msgstr "" +"metche monitoruje změny \"stavu systému\". Hodinu poté, co jsou zaznamenány " +"poslední změny, je poslána zpráva popisující změny zaměřená na:\n" +" - soubory uvnitř sledovaného adresáře (výchozí hodnotou je /etc),\n" +" - uživatelem spravovaný soubor(y) changelog (je-li nastaveno),\n" +" - seznam instalovaných balíčků Debianu (je-li nastaveno)." + +#. Type: string +#. Description +#: ../templates:1001 +msgid "" +"Please enter the e-mail that should receive these reports. It typically " +"corresponds to the alias or mailing-list used by system administrators for " +"this computer." +msgstr "" +"Zadejte prosím emailovou adresu, na kterou budou tyto zprávy posílány. " +"Obvykle se používá jméno nebo adresář používaný pro administrátora tohoto " +"počítače." + +#. Type: string +#. Description +#: ../templates:1001 +#, fuzzy +msgid "" +"Note: by default, metche does not send detailed diffs describing file " +"changes as this can leak confidential information. If you want to use this " +"feature, you are strongly encouraged to turn on GPG encryption at the same " +"time. See the metche(8) man page and the configuration file for more details." +msgstr "" +"Poznámka: ve výchozím nastavení metche neposílá detailní rozdíly popisující " +"změny souboru, protože by tak mohlo dojít k úniku důvěrných informací. Pokud " +"si přejete použít tuto vlastnost, silně doporučujeme zapnout šifrování GPG. " +"Pro další informace se podívejte na konfigurační soubor a manuálovou stránku " +"metche(8)." + +#. Type: select +#. Choices +#: ../templates:2001 +msgid "Single changelog file" +msgstr "Jeden soubor changelog" + +#. Type: select +#. Choices +#: ../templates:2001 +msgid "Multiple changelog files" +msgstr "Více souborů changelog" + +#. Type: select +#. Choices +#: ../templates:2001 +msgid "No changelog monitoring" +msgstr "Bez sledování changelogu" + +#. Type: select +#. Description +#: ../templates:2002 +msgid "Changelog monitoring type:" +msgstr "Typ sledování changelogu:" + +#. Type: select +#. Description +#: ../templates:2002 +msgid "" +"metche can monitor one or more changelogs written by the system " +"administrators." +msgstr "" +"metche může sledovat jeden nebo více changelogů napsaných systémovými " +"administrátory." + +#. Type: select +#. Description +#: ../templates:2002 +msgid "" +"These changelogs should contain comments describing the changes made to the " +"system. The easiest way to organize these comments is to put them all " +"together in one file." +msgstr "" +"Tyto seznamy změn mohou obsahovat komentáře popisující změny provedené " +"systémem. Nejjednodušší cestou pro uspořádání těchto komentářů je umístit je " +"všechny do jednoho souboru." + +#. Type: select +#. Description +#: ../templates:2002 +msgid "" +"Another possibility is to have a subdirectory for each administrative task " +"with a file named \"Changelog\". This way, you can store source code or " +"configuration examples along with the documentation on how they have been " +"used." +msgstr "" +"Další možností je vytvořit pro každou administrativní úlohu podadresář spolu " +"se souborem pojmenovaným \"Changelog\". Takto můžete uchovávat zdrojové kódy " +"a příklady s konfigurací společně s použitou dokumentací." + +#. Type: string +#. Description +#: ../templates:3001 +msgid "Changelog file to be monitored:" +msgstr "Sledovaný soubor:" + +#. Type: string +#. Description +#: ../templates:3001 +msgid "This option sets the path of the changelog file to be monitored." +msgstr "Touto volbou nastavíte cestu ke sledovanému souboru." + +#. Type: string +#. Description +#: ../templates:4001 +msgid "Changelog directory to be monitored:" +msgstr "Sledovaný adresář:" + +#. Type: string +#. Description +#: ../templates:4001 +msgid "" +"This option sets the path to the root directory containing the Changelogs. " +"Each \"Changelog\" file should be in a sub-directory of this directory." +msgstr "" +"Tato volba nastaví cestu do kořenového adresáře obsahujícího soubory změn. " +"Všechny soubory \"Changelog\" by měly být v podadresáři tohoto adresáře." diff --git a/debian/po/fr.po b/debian/po/fr.po new file mode 100644 index 0000000..6759d64 --- /dev/null +++ b/debian/po/fr.po @@ -0,0 +1,158 @@ +# metche - configuration monitor to ease collective administration +# Copyright (C) 2004-2006 boum.org collective +# This file is distributed under the same license as the metche package. +# boum.org collective 2004 +# +msgid "" +msgstr "" +"Project-Id-Version: metche_1:1.0-2\n" +"Report-Msgid-Bugs-To: metche@lists.riseup.net\n" +"POT-Creation-Date: 2006-09-16 17:02+0200\n" +"PO-Revision-Date: 2006-04-14 15:39+0100\n" +"Last-Translator: Cyril Brulebois \n" +"Language-Team: French \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Type: string +#. Description +#: ../templates:1001 +msgid "E-mail address receiving metche reports:" +msgstr "Adresse électronique qui recevra les rapports de metche :" + +#. Type: string +#. Description +#: ../templates:1001 +msgid "" +"metche monitors \"system state\" changes. An hour after the last change has " +"been recorded an e-mail report is sent describing changes made to:\n" +" - files inside the watched directory (/etc by default),\n" +" - user maintainted changelog file(s) (if configured to do so),\n" +" - the list of installed Debian packages (if configured to do so)." +msgstr "" +"Metche surveille les changements d'« état système ». Une heure après " +"l'enregistrement du dernier changement, un rapport est envoyé par courriel ; " +"il décrit les modifications :\n" +" - des fichiers dans les répertoires surveillés (/etc par défaut) ;\n" +" - des journaux de modifications (« changelog ») gérés par\n" +" l'utilisateur (si configuré ainsi) ;\n" +" - de la liste des paquets Debian installés (si configuré ainsi)." + +#. Type: string +#. Description +#: ../templates:1001 +msgid "" +"Please enter the e-mail that should receive these reports. It typically " +"corresponds to the alias or mailing-list used by system administrators for " +"this computer." +msgstr "" +"Veuillez indiquer l'adresse électronique qui recevra ces rapports. Cela " +"correspond généralement à l'alias ou à la liste de diffusion utilisé par les " +"administrateurs de cette machine." + +#. Type: string +#. Description +#: ../templates:1001 +msgid "" +"Note: by default, metche does not send detailed diffs describing file " +"changes as this can leak confidential information. If you want to use this " +"feature, you are strongly encouraged to turn on GPG encryption at the same " +"time. See the metche(8) man page and the configuration file for more details." +msgstr "" +"Note : par défaut, metche n'envoie pas de détail des différences entre les " +"versions successives des fichiers puisque des informations confidentielles " +"peuvent en être tirées. Si vous voulez utiliser cette fonctionnalité, " +"l'utilisation simultanée du chiffrement GPG est vivement recommandée. " +"Veuillez consulter la page de manuel metche(8) et le fichier de " +"configuration pour plus de détails." + +#. Type: select +#. Choices +#: ../templates:2001 +msgid "Single changelog file" +msgstr "Journal de modifications unique" + +#. Type: select +#. Choices +#: ../templates:2001 +msgid "Multiple changelog files" +msgstr "Journaux de modifications multiples" + +#. Type: select +#. Choices +#: ../templates:2001 +msgid "No changelog monitoring" +msgstr "Aucune surveillance de journal de modifications" + +#. Type: select +#. Description +#: ../templates:2002 +msgid "Changelog monitoring type:" +msgstr "Type de surveillance de journal de modifications :" + +#. Type: select +#. Description +#: ../templates:2002 +msgid "" +"metche can monitor one or more changelogs written by the system " +"administrators." +msgstr "" +"Metche peut surveiller un ou plusieurs journaux de modifications maintenus " +"par les administrateurs système." + +#. Type: select +#. Description +#: ../templates:2002 +msgid "" +"These changelogs should contain comments describing the changes made to the " +"system. The easiest way to organize these comments is to put them all " +"together in one file." +msgstr "" +"Ces journaux de modifications devraient contenir des commentaires décrivant " +"les modifications appliquées au système. Le plus simple pour organiser ces " +"commentaires est de tous les rassembler en un seul fichier." + +#. Type: select +#. Description +#: ../templates:2002 +msgid "" +"Another possibility is to have a subdirectory for each administrative task " +"with a file named \"Changelog\". This way, you can store source code or " +"configuration examples along with the documentation on how they have been " +"used." +msgstr "" +"Une autre possibilité est d'avoir un sous-répertoire pour chaque tâche " +"administrative, avec un fichier « Changelog ». De cette manière, vous pouvez " +"conserver du code source ou des exemples de configuration en même temps que " +"la documentation concernant leur utilisation." + +#. Type: string +#. Description +#: ../templates:3001 +msgid "Changelog file to be monitored:" +msgstr "Journal de modifications à surveiller :" + +#. Type: string +#. Description +#: ../templates:3001 +msgid "This option sets the path of the changelog file to be monitored." +msgstr "" +"Cette option spécifie le chemin du journal de modifications à surveiller." + +#. Type: string +#. Description +#: ../templates:4001 +msgid "Changelog directory to be monitored:" +msgstr "Répertoire de journaux de modifications à surveiller :" + +#. Type: string +#. Description +#: ../templates:4001 +msgid "" +"This option sets the path to the root directory containing the Changelogs. " +"Each \"Changelog\" file should be in a sub-directory of this directory." +msgstr "" +"Cette option spécifie le chemin du répertoire principal contenant les " +"journaux de modifications. Chaque fichier « Changelog » devrait se situer " +"dans un sous-répertoire de ce répertoire." diff --git a/debian/po/templates.pot b/debian/po/templates.pot index f955c87..d7c2422 100644 --- a/debian/po/templates.pot +++ b/debian/po/templates.pot @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: metche@lists.riseup.net\n" -"POT-Creation-Date: 2006-04-08 18:31-0400\n" +"POT-Creation-Date: 2006-09-16 17:02+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -18,13 +18,13 @@ #. Type: string #. Description -#: ../templates:4 +#: ../templates:1001 msgid "E-mail address receiving metche reports:" msgstr "" #. Type: string #. Description -#: ../templates:4 +#: ../templates:1001 msgid "" "metche monitors \"system state\" changes. An hour after the last change has " "been recorded an e-mail report is sent describing changes made to:\n" @@ -35,7 +35,7 @@ #. Type: string #. Description -#: ../templates:4 +#: ../templates:1001 msgid "" "Please enter the e-mail that should receive these reports. It typically " "corresponds to the alias or mailing-list used by system administrators for " @@ -44,41 +44,41 @@ #. Type: string #. Description -#: ../templates:4 +#: ../templates:1001 msgid "" "Note: by default, metche does not send detailed diffs describing file " "changes as this can leak confidential information. If you want to use this " -"feature, we strongly encourage you to turn on GPG encryption at the same " +"feature, you are strongly encouraged to turn on GPG encryption at the same " "time. See the metche(8) man page and the configuration file for more details." msgstr "" #. Type: select #. Choices -#: ../templates:23 +#: ../templates:2001 msgid "Single changelog file" msgstr "" #. Type: select #. Choices -#: ../templates:23 +#: ../templates:2001 msgid "Multiple changelog files" msgstr "" #. Type: select #. Choices -#: ../templates:23 +#: ../templates:2001 msgid "No changelog monitoring" msgstr "" #. Type: select #. Description -#: ../templates:24 +#: ../templates:2002 msgid "Changelog monitoring type:" msgstr "" #. Type: select #. Description -#: ../templates:24 +#: ../templates:2002 msgid "" "metche can monitor one or more changelogs written by the system " "administrators." @@ -86,7 +86,7 @@ #. Type: select #. Description -#: ../templates:24 +#: ../templates:2002 msgid "" "These changelogs should contain comments describing the changes made to the " "system. The easiest way to organize these comments is to put them all " @@ -95,7 +95,7 @@ #. Type: select #. Description -#: ../templates:24 +#: ../templates:2002 msgid "" "Another possibility is to have a subdirectory for each administrative task " "with a file named \"Changelog\". This way, you can store source code or " @@ -105,25 +105,25 @@ #. Type: string #. Description -#: ../templates:39 +#: ../templates:3001 msgid "Changelog file to be monitored:" msgstr "" #. Type: string #. Description -#: ../templates:39 +#: ../templates:3001 msgid "This option sets the path of the changelog file to be monitored." msgstr "" #. Type: string #. Description -#: ../templates:44 +#: ../templates:4001 msgid "Changelog directory to be monitored:" msgstr "" #. Type: string #. Description -#: ../templates:44 +#: ../templates:4001 msgid "" "This option sets the path to the root directory containing the Changelogs. " "Each \"Changelog\" file should be in a sub-directory of this directory." diff --git a/debian/postinst b/debian/postinst index 7cba541..3c7210c 100644 --- a/debian/postinst +++ b/debian/postinst @@ -1,37 +1,57 @@ #!/bin/sh -CONFIGFILE=/etc/metche.conf set -e + . /usr/share/debconf/confmodule -cp -a -f $CONFIGFILE $CONFIGFILE.tmp +case "$1" in + configure) + TEMPFILE=`tempfile` + cat "/usr/share/doc/metche/examples/metche.conf.default" > "$TEMPFILE" -db_get metche/email -EMAIL_ADDRESS="$RET" -sed -e "s/^ *EMAIL_ADDRESS=.*/EMAIL_ADDRESS=\"$EMAIL_ADDRESS\"/" -i $CONFIGFILE.tmp + db_get metche/email + EMAIL_ADDRESS="$RET" + sed -e "s/^ *EMAIL_ADDRESS=.*/EMAIL_ADDRESS=\"$EMAIL_ADDRESS\"/" \ + -i "$TEMPFILE" -db_get metche/changelog/type -case "$RET" in -"Single changelog file") - db_get metche/changelog/file - CHANGELOG_FILE="$RET" - sed -e "s@^[# ]*CHANGELOG_FILE=.*@CHANGELOG_FILE=\"$CHANGELOG_FILE\"@" \ - -e "s@^[# ]*CHANGELOG_DIR@#CHANGELOG_DIR@" -i $CONFIGFILE.tmp + db_get metche/changelog/type + case "$RET" in + "Single changelog file") + db_get metche/changelog/file + CHANGELOG_FILE="$RET" + sed -e "s@^[# ]*CHANGELOG_FILE=.*@CHANGELOG_FILE=\"$CHANGELOG_FILE\"@" \ + -e "s@^[# ]*CHANGELOG_DIR@#CHANGELOG_DIR@" -i "$TEMPFILE" + ;; + "Multiple changelog files") + db_get metche/changelog/directory + CHANGELOG_DIR="$RET" + sed -e "s@^[# ]*CHANGELOG_DIR=.*@CHANGELOG_DIR=\"$CHANGELOG_DIR\"@" \ + -e "s@^[# ]*CHANGELOG_FILE@#CHANGELOG_FILE@" -i "$TEMPFILE" + ;; + "No changelog monitoring") + sed -e "s@^[# ]*CHANGELOG_FILE@#CHANGELOG_FILE@" \ + -e "s@^[# ]*CHANGELOG_DIR@#CHANGELOG_DIR@" -i "$TEMPFILE" + ;; + esac + + ucf --debconf-ok "$TEMPFILE" "/etc/metche.conf" + + rm -f "$TEMPFILE" + + metche cron ;; -"Multiple changelog files") - db_get metche/changelog/directory - CHANGELOG_DIR="$RET" - sed -e "s@^[# ]*CHANGELOG_DIR=.*@CHANGELOG_DIR=\"$CHANGELOG_DIR\"@" \ - -e "s@^[# ]*CHANGELOG_FILE@#CHANGELOG_FILE@" -i $CONFIGFILE.tmp + + abort-upgrade|abort-remove|abort-deconfigure) ;; -"No changelog monitoring") - sed -e "s@^[# ]*CHANGELOG_FILE@#CHANGELOG_FILE@" \ - -e "s@^[# ]*CHANGELOG_DIR@#CHANGELOG_DIR@" -i $CONFIGFILE.tmp + + *) + echo "postinst called with onkwnow argument '$1'" >&2 + exit 0 ;; esac -mv -f $CONFIGFILE.tmp $CONFIGFILE +#DEBHELPER# -metche cron +exit 0 -#DEBHELPER# +# vim: et sw=4 diff --git a/debian/postrm b/debian/postrm new file mode 100644 index 0000000..5677f42 --- /dev/null +++ b/debian/postrm @@ -0,0 +1,42 @@ +#! /bin/sh + +set -e + +case "$1" in + purge) + # Remove metche.conf from ucf's database if ucf is available + if [ -x /usr/bin/ucf ]; then + ucf --purge /etc/metche.conf + fi + + # Remove possible conffiles + for conffile in metche.conf.dpkg-dist metche.conf.dpkg-old \ + metche.conf.old metche.conf metche.conf.ucf-dist; do + if [ -e "/etc/$conffile" ]; then + rm -f "/etc/$conffile" + fi + done + + # Remove cron script if found + if [ -e /etc/cron.d/metche ]; then + rm -f /etc/cron.d/metche + fi + + # Remove data directory + if [ -d /var/lib/metche ]; then + rm -rf /var/lib/metche + fi + ;; + + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument '$1'" >&2 + exit 0 + ;; +esac + +#DEBHELPER# + +# vim: et sw=4 diff --git a/debian/rules b/debian/rules index ee0fd9c..ac12ce3 100755 --- a/debian/rules +++ b/debian/rules @@ -22,7 +22,6 @@ dh_clean -k dh_installdirs cp $(CURDIR)/metche $(DESTDIR)/usr/sbin - cp $(CURDIR)/metche.conf.default $(DESTDIR)/etc/metche.conf cp $(CURDIR)/metche.8 $(DESTDIR)/usr/share/man/man8 chown root:staff $(DESTDIR)/var/lib/metche chmod 750 $(DESTDIR)/var/lib/metche diff --git a/debian/templates b/debian/templates index cf9f7d5..4b0b3f7 100644 --- a/debian/templates +++ b/debian/templates @@ -1,6 +1,6 @@ Template: metche/email Type: string -Default: root +Default: root@localhost _Description: E-mail address receiving metche reports: metche monitors "system state" changes. An hour after the last change has been recorded an e-mail report is sent describing changes made to: @@ -14,12 +14,13 @@ . Note: by default, metche does not send detailed diffs describing file changes as this can leak confidential information. If you want to use - this feature, we strongly encourage you to turn on GPG encryption at the + this feature, you are strongly encouraged to turn on GPG encryption at the same time. See the metche(8) man page and the configuration file for more details. Template: metche/changelog/type Type: select +Default: Single changelog file __Choices: Single changelog file, Multiple changelog files, No changelog monitoring _Description: Changelog monitoring type: metche can monitor one or more changelogs written by the system @@ -36,11 +37,13 @@ Template: metche/changelog/file Type: string +Default: /root/Changelog _Description: Changelog file to be monitored: This option sets the path of the changelog file to be monitored. Template: metche/changelog/directory Type: string +Default: /root/changelogs _Description: Changelog directory to be monitored: This option sets the path to the root directory containing the Changelogs. Each "Changelog" file should be in a sub-directory of this directory.