|
|
|
@ -45,18 +45,18 @@ if [ -z "$language" ]; then |
|
|
|
ynh_app_setting_set $app language $language |
|
|
|
fi |
|
|
|
|
|
|
|
if [ "$is_public" = "Yes" ]; then |
|
|
|
if [ "${is_public,,}" = "yes" ]; then |
|
|
|
ynh_app_setting_set $app is_public 1 # Fixe is_public en booléen |
|
|
|
is_public=1 |
|
|
|
elif [ "$is_public" = "No" ]; then |
|
|
|
elif [ "${is_public,,}" = "no" ]; then |
|
|
|
ynh_app_setting_set $app is_public 0 |
|
|
|
is_public=0 |
|
|
|
fi |
|
|
|
|
|
|
|
if [ "$multisite" = "Yes" ]; then |
|
|
|
if [ "${multisite,,}" = "yes" ]; then |
|
|
|
ynh_app_setting_set $app multisite 1 # Fixe multisite en booléen |
|
|
|
multisite=1 |
|
|
|
elif [ "$multisite" = "No" ]; then |
|
|
|
elif [ "${multisite,,}" = "no" ]; then |
|
|
|
ynh_app_setting_set $app multisite 0 |
|
|
|
multisite=0 |
|
|
|
fi |
|
|
|
@ -154,6 +154,8 @@ update_plugin () { |
|
|
|
update_plugin simple-ldap-login |
|
|
|
update_plugin companion-auto-update |
|
|
|
$wpcli_alias plugin activate companion-auto-update $plugin_network |
|
|
|
update_plugin wp-fail2ban |
|
|
|
$wpcli_alias plugin activate wp-fail2ban $plugin_network |
|
|
|
|
|
|
|
# Disable broken plugin http-authentication |
|
|
|
$wpcli_alias plugin is-installed http-authentication && $wpcli_alias plugin deactivate http-authentication |
|
|
|
@ -176,6 +178,12 @@ chown -R $app: $final_path |
|
|
|
# Sauf le fichier de config wp-config.php qui appartient à root |
|
|
|
chown root: $final_path/wp-config.php |
|
|
|
|
|
|
|
#================================================= |
|
|
|
# UPGRADE FAIL2BAN |
|
|
|
#================================================= |
|
|
|
|
|
|
|
ynh_add_fail2ban_config "/var/log/auth.log" "Authentication (attempt for unknown user|failure for) .* from <HOST>" 5 |
|
|
|
|
|
|
|
#================================================= |
|
|
|
# SETUP SSOWAT |
|
|
|
#================================================= |
|
|
|
|