several improvement and armonisation in filefct.sh, module auth and patch_snmp improved

This commit is contained in:
2022-01-27 13:17:56 +01:00
parent baac34cb85
commit 55a9e49101
16 changed files with 204 additions and 116 deletions

View File

@@ -13,7 +13,7 @@
# * MAIL_RELAY: Name of the mail relay server
# ------------------------------------------------------------------------------
export VER_conf_mail="0.0.5"
export VER_conf_mail="0.0.6"
export DEP_conf_mail="upgrade_dist"
conf_mail()
@@ -24,12 +24,12 @@ conf_mail()
local pfmain="/etc/postfix/main.cf"
prnt I "Configuration de postfix..."
installfile postfix/main.cf $pfmain
tagfile $pfmain
install_file postfix/main.cf $pfmain
tag_file $pfmain
sed -i -e "s/@HOSTNAME@/$HOSTNAME/" -e "s/@REALM@/$REALM/" \
-e "s/@MAIL_RELAY@/$MAIL_RELAY/" $pfmain
tagfile /etc/mailname
tag_file /etc/mailname
echo $HOSTNAME.$REALM > /etc/mailname
svc_restart postfix
@@ -41,7 +41,7 @@ precheck_conf_mail()
prnt E "Aucun domaine principal renseigné."
die 158
fi
file_exists postfix/main.cf
file_must_exists postfix/main.cf
}
export -f conf_mail