From 144ff1e27ae3c63f246e6f6f3c3c67fad36a115e Mon Sep 17 00:00:00 2001 From: Benjamin Sonntag Date: Sun, 24 Jun 2018 19:40:22 +0200 Subject: [PATCH] [enh] removing latest lintian exceptions, no Error, no Warnings ! --- Makefile | 3 ++- debian/alternc-slave.lintian | 22 ---------------------- debian/alternc.lintian | 6 ------ debian/control | 1 + debian/rules | 4 ---- install/alternc.install | 36 ++++++++++++++++++++++++++---------- 6 files changed, 29 insertions(+), 43 deletions(-) delete mode 100644 debian/alternc-slave.lintian delete mode 100644 debian/alternc.lintian diff --git a/Makefile b/Makefile index 94cd26f0..0ddc32bd 100644 --- a/Makefile +++ b/Makefile @@ -56,7 +56,8 @@ install-alternc: install-common # Web Panel test -d $(DESTDIR)/usr/share/alternc/panel || mkdir $(DESTDIR)/usr/share/alternc/panel cp -r bureau/* $(DESTDIR)/usr/share/alternc/panel - sed -i -e "s/@@REPLACED_DURING_BUILD@@/${MAJOR}/" $(DESTDIR)/usr/share/alternc/panel/class/local.php + sed -i -e "s/@@REPLACED_DURING_BUILD@@/${MAJOR}/" $(DESTDIR)/usr/share/alternc/panel/class/local.php $(DESTDIR)/usr/share/alternc/install/alternc.install + help2man -n --no-discard-stderr --section 8 $(DESTDIR)/usr/share/alternc/install/alternc.install -o $(DESTDIR)/usr/share/man/man8/alternc.install.8 chown -R root:root $(DESTDIR)/usr/share/alternc/panel chmod -R 644 $(DESTDIR)/usr/share/alternc/panel chmod -R a+X $(DESTDIR)/usr/share/alternc/panel diff --git a/debian/alternc-slave.lintian b/debian/alternc-slave.lintian deleted file mode 100644 index 49a116ea..00000000 --- a/debian/alternc-slave.lintian +++ /dev/null @@ -1,22 +0,0 @@ -alternc-slave: setuid-binary usr/lib/alternc/mem_add 4750 root/www-data -alternc-slave: setuid-binary usr/lib/alternc/mem_del 4750 root/www-data -alternc-slave: setuid-binary usr/lib/alternc/quota_edit 4750 root/www-data -alternc-slave: setuid-binary usr/lib/alternc/quota_get 4750 root/www-data -alternc-slave: executable-is-not-world-readable usr/lib/alternc/fixperms.sh 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/mem_add 4750 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/mem_del 4750 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/quota_delete 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/quota_get 4750 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/quota_edit 4750 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/quota_edit.sh 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/quota_get.sh 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/quota_init 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/rawstat.daily 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/sendmail 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/slave_dns 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/spoolsize.php 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/sqlbackup.sh 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/update_domains.sh 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/functions_hosting.sh 0750 != 0755 -alternc-slave: executable-is-not-world-readable usr/lib/alternc/functions_dns.sh 0750 != 0755 -alternc-slave: non-standard-dir-in-var var/backups/ diff --git a/debian/alternc.lintian b/debian/alternc.lintian deleted file mode 100644 index c91a58f3..00000000 --- a/debian/alternc.lintian +++ /dev/null @@ -1,6 +0,0 @@ -alternc: non-standard-dir-perm var/lib/alternc/backups/ 0700 != 0755 -alternc: setuid-binary usr/lib/alternc/quota_edit 4750 root/www-data -alternc: setuid-binary usr/lib/alternc/quota_get 4750 root/www-data -alternc: setuid-binary usr/lib/alternc/mem_add 4750 root/www-data -alternc: setuid-binary usr/lib/alternc/mem_del 4750 root/www-data -alternc: setuid-binary usr/lib/alternc/db_create 4750 root/www-data diff --git a/debian/control b/debian/control index 75bc485f..e6904d47 100644 --- a/debian/control +++ b/debian/control @@ -3,6 +3,7 @@ Section: admin Priority: optional Maintainer: Benjamin Sonntag Build-Depends-Indep: perl + , help2man , findutils (>= 4.1.7) , gettext (>= 0.10.40-5) Build-Depends: debhelper (>= 9) diff --git a/debian/rules b/debian/rules index 8407afd6..03b7b0eb 100755 --- a/debian/rules +++ b/debian/rules @@ -17,10 +17,6 @@ override_dh_install: $(MAKE) install-slave DESTDIR=$(CURDIR)/debian/alternc-slave $(MAKE) install-api DESTDIR=$(CURDIR)/debian/alternc-api -override_dh_fixperms: - dh_fixperms - chmod 700 debian/alternc/var/lib/alternc/backups - %: dh $@ diff --git a/install/alternc.install b/install/alternc.install index a704d54d..49eabe26 100755 --- a/install/alternc.install +++ b/install/alternc.install @@ -22,21 +22,28 @@ # Purpose of file: Main install script, launch it anytime ;) # ---------------------------------------------------------------------- -# Somes check before start operations -if [ `id -u` -ne 0 ]; then - echo "must be launched as root" - exit 1 -fi usage(){ declare -a out [[ $# -ne 0 ]] && out+=("\e[31mWarning: $@ \e[0m") out+=(" -Usage: ${BASH_SOURCE[0]} [options] - -n|--no-fixperms Skip the -often long- fixperms action - -f|--force Force the execution even if some files changed - -s|--slave Mandatory on instances runnning the alternc-slave module - -h|--help This help +Usage: alternc.install [-n] [-f] [-s] + or alternc.install [-h] [-v] +Launch the template installation and service configuration process of AlternC. + +This script should be launched by root after an AlternC package or plugin +installation or upgrade. +It should be harmless to launch it anytime, (it will restart services though). + +Options: + -n, --no-fixperms Skip the -often long- fixperms action + -f, --force Force the execution even if some files changed + -s, --slave Mandatory on instances runnning the alternc-slave module + -h, --help This help + -v, --version Show AlternC version + +AlternC is a free software distributed under GPL-v2+ license. +For more information see https://alternc.com/ ") echo -e "${out[@]}" exit 2 @@ -45,6 +52,9 @@ for i in $*; do case "$i" in -h|--help) usage; shift;; + -v|--version) + echo "AlternC - hosting software control panel, version @@REPLACED_DURING_BUILD@@" + exit 2;; -n|--no-fixperms) export nofixperms=1; shift;; -f|--force) @@ -58,6 +68,12 @@ for i in $*; do esac done +# Somes check before start operations +if [ `id -u` -ne 0 ]; then + echo "must be launched as root" + exit 1 +fi + . /usr/lib/alternc/functions.sh # Lock the jobs !