diff --git a/data/helpers.d/filesystem b/data/helpers.d/filesystem index c07de2ec..badc0e99 100644 --- a/data/helpers.d/filesystem +++ b/data/helpers.d/filesystem @@ -60,8 +60,16 @@ ynh_backup() { # ============================================================================== # Be sure the source path is not empty [[ -e "${SRC_PATH}" ]] || { - echo "Source path '${SRC_PATH}' does not exist" >&2 - return 1 + echo "!!! Source path '${SRC_PATH}' does not exist !!!" >&2 + + # This is a temporary fix for fail2ban config files missing after the migration to stretch. + if echo "${SRC_PATH}" | grep --quiet "/etc/fail2ban" + then + touch "${SRC_PATH}" + echo "The missing file will be replaced by a dummy one for the backup !!!" >&2 + else + return 1 + fi } # Transform the source path as an absolute path