Merge branch 'dev' into migrate-to-bookworm

This commit is contained in:
Salamandar 2024-07-08 22:47:09 +02:00
commit b289de3eca
22 changed files with 74 additions and 47 deletions

8
debian/changelog vendored
View file

@ -1,3 +1,11 @@
yunohost (11.2.20.2) stable; urgency=low
- Fix service enable/disable auto-ignoring diagnosis entries ([#1886](http://github.com/YunoHost/yunohost/pull/1886))
Thanks to all contributors <3 ! (OniriCorpe)
-- Alexandre Aubin <alex.aubin@mailoo.org> Wed, 03 Jul 2024 21:51:50 +0200
yunohost (11.2.20.1) stable; urgency=low
- helpers2.1: typo (1ed56952e)

2
debian/control vendored
View file

@ -28,7 +28,7 @@ Depends: ${python3:Depends}, ${misc:Depends}
, redis-server
, acl
, git, curl, wget, cron, unzip, jq, bc, at, procps, j2cli
, lsb-release, haveged, fake-hwclock, equivs, lsof, whois
, lsb-release, haveged, fake-hwclock, lsof, whois
Recommends: yunohost-admin
, ntp, inetutils-ping | iputils-ping
, bash-completion, rsyslog

View file

@ -186,21 +186,19 @@ ynh_package_install_from_equivs() {
# Build and install the package
local TMPDIR=$(mktemp --directory)
# Make sure to delete the legacy compat file
# It's now handle somewhat magically through the control file
rm -f /usr/share/equivs/template/debian/compat
mkdir -p ${TMPDIR}/${pkgname}/DEBIAN/
# Note that the cd executes into a sub shell
# Create a fake deb package with equivs-build and the given control file
# Install the fake package without its dependencies with dpkg
# Install missing dependencies with ynh_package_install
ynh_wait_dpkg_free
cp "$controlfile" "${TMPDIR}/control"
cp "$controlfile" "${TMPDIR}/${pkgname}/DEBIAN/control"
(
cd "$TMPDIR"
LC_ALL=C equivs-build ./control 2>&1
LC_ALL=C dpkg --force-depends --install "./${pkgname}_${pkgversion}_all.deb" 2>&1 | tee ./dpkg_log
# Install the fake package without its dependencies with dpkg --force-depends
LC_ALL=C dpkg-deb --build ${pkgname} ${pkgname}.deb > ./dpkg_log 2>&1 || { cat ./dpkg_log; false; }
LC_ALL=C dpkg --force-depends --install "./${pkgname}.deb" 2>&1 | tee ./dpkg_log
)
ynh_package_install --fix-broken \
@ -323,6 +321,7 @@ Package: ${dep_app}-ynh-deps
Version: ${version}
Depends: ${dependencies}
Architecture: all
Maintainer: root@localhost
Description: Fake package for ${app} (YunoHost app) dependencies
This meta-package is only responsible of installing its dependencies.
EOF

View file

@ -90,27 +90,25 @@ ynh_apt_install_dependencies() {
dependencies="$current_dependencies, $dependencies"
fi
# #############################
# Actual install using equivs #
# #############################
# ################
# Actual install #
# ################
# Prepare the virtual-dependency control file for equivs
# Prepare the virtual-dependency control file for dpkg-deb --build
local TMPDIR=$(mktemp --directory)
cat >${TMPDIR}/control <<EOF # Make a control file for equivs-build
mkdir -p ${TMPDIR}/${app_ynh_deps}/DEBIAN
cat >${TMPDIR}/${app_ynh_deps}/DEBIAN/control <<EOF
Section: misc
Priority: optional
Package: ${app_ynh_deps}
Version: ${version}
Depends: ${dependencies}
Architecture: all
Maintainer: root@localhost
Description: Fake package for ${app} (YunoHost app) dependencies
This meta-package is only responsible of installing its dependencies.
EOF
# Make sure to delete equivs' legacy compat file
# It's now handle somewhat magically through the control file
rm -f /usr/share/equivs/template/debian/compat
_ynh_apt update
_ynh_wait_dpkg_free
@ -119,8 +117,8 @@ EOF
# NB: this is in a subshell (though not sure why exactly not just use pushd/popd...)
cd "$TMPDIR"
# Install the fake package without its dependencies with dpkg --force-depends
LC_ALL=C equivs-build ./control > ./equivs_log 2>&1 || { cat ./equivs_log; false; }
LC_ALL=C dpkg --force-depends --install "./${app_ynh_deps}_${version}_all.deb" > ./dpkg_log 2>&1
LC_ALL=C dpkg-deb --build ${app_ynh_deps} ${app_ynh_deps}.deb > ./dpkg_log 2>&1 || { cat ./dpkg_log; false; }
LC_ALL=C dpkg --force-depends --install "./${app_ynh_deps}.deb" > ./dpkg_log 2>&1
)
# Then install the missing dependencies with apt install

View file

@ -782,4 +782,4 @@
"user_import_partial_failed": "L'operació d'importació dels usuaris ha fallat parcialment",
"domain_dns_push_record_failed": "No s'ha pogut {action} el registre {type}/{name}: {error}",
"registrar_infos": "Informació del registrador"
}
}

View file

@ -782,4 +782,4 @@
"dyndns_set_recovery_password_failed": "Konnte Wiederherstellungspasswort nicht einstellen: {error}",
"dyndns_set_recovery_password_success": "Wiederherstellungspasswort eingestellt!",
"global_settings_setting_ssh_port_help": "Ein Port unter 1024 wird bevorzugt, um Kaperversuche durch Nicht-Administratordienste auf dem Remote-Computer zu verhindern. Sie sollten auch vermeiden, einen bereits verwendeten Port zu verwenden, z. B. 80 oder 443."
}
}

View file

@ -248,6 +248,13 @@
"diagnosis_http_special_use_tld": "Domain {domain} is based on a special-use top-level domain (TLD) such as .local or .test and is therefore not expected to be exposed outside the local network.",
"diagnosis_http_timeout": "Timed-out while trying to contact your server from the outside. It appears to be unreachable.<br>1. The most common cause for this issue is that port 80 (and 443) <a href='https://yunohost.org/isp_box_config'>are not correctly forwarded to your server</a>.<br>2. You should also make sure that the service nginx is running<br>3. On more complex setups: make sure that no firewall or reverse-proxy is interfering.",
"diagnosis_http_unreachable": "Domain {domain} appears unreachable through HTTP from outside the local network.",
"diagnosis_ignore_already_filtered": "(There is already a diagnosis {category} filter with these criterias)",
"diagnosis_ignore_criteria_error": "Criterias should be of the form key=value (e.g. domain=yolo.test)",
"diagnosis_ignore_filter_added": "Added a {category} diagnosis filter",
"diagnosis_ignore_filter_removed": "Removed a {category} diagnosis filter",
"diagnosis_ignore_missing_criteria": "You should provide at least one criteria being the diagnosis category to ignore",
"diagnosis_ignore_no_filter_found": "(There is no such diagnosis {category} filter with these criterias to remove)",
"diagnosis_ignore_no_issue_found": "No issues was found matching the given criteria.",
"diagnosis_ignored_issues": "(+ {nb_ignored} ignored issue(s))",
"diagnosis_ip_broken_dnsresolution": "Domain name resolution seems to be broken for some reason… Is a firewall blocking DNS requests?",
"diagnosis_ip_broken_resolvconf": "Domain name resolution seems to be broken on your server, which seems related to <code>/etc/resolv.conf</code> not pointing to <code>127.0.0.1</code>.",

View file

@ -507,4 +507,4 @@
"global_settings_setting_postfix_compatibility_help": "Kongruo vs sekureca kompromiso por la Postfix-servilo. Afektas la ĉifradojn (kaj aliajn aspektojn pri sekureco)",
"global_settings_setting_ssh_compatibility_help": "Kongruo vs sekureca kompromiso por la SSH-servilo. Afektas la ĉifradojn (kaj aliajn aspektojn pri sekureco)",
"global_settings_setting_smtp_allow_ipv6_help": "Permesu la uzon de IPv6 por ricevi kaj sendi poŝton"
}
}

View file

@ -782,4 +782,4 @@
"dyndns_set_recovery_password_success": "¡Password de recuperación establecida!",
"global_settings_setting_dns_exposure_help": "NB: Esto afecta únicamente a la configuración recomentada de DNS y en las pruebas de diagnóstico. No afecta a la configuración del sistema.",
"global_settings_setting_ssh_port_help": "Un puerto menor a 1024 es preferible para evitar intentos de usurpación por servicios no administrativos en la máquina remota. También debe de evitar usar un puerto ya en uso, como el 80 o 443."
}
}

View file

@ -782,4 +782,4 @@
"dyndns_set_recovery_password_failed": "Berreskuratze-pasahitza ezartzeak huts egin du: {error}",
"dyndns_set_recovery_password_success": "Berreskuratze-pasahitza ezarri da!",
"global_settings_setting_ssh_port_help": "1024 baino ataka txikiago bat izan beharko litzateke, zerbitzu ez-administratzaileek urruneko makinan usurpazio-saiorik egin ez dezaten. Lehendik ere erabiltzen ari diren atakak ere ekidin beharko zenituzke, 80 edo 443 kasu."
}
}

View file

@ -565,4 +565,4 @@
"global_settings_setting_webadmin_allowlist_enabled_help": "فقط به برخی از IP ها اجازه دسترسی به مدیریت وب را بدهید.",
"global_settings_setting_smtp_allow_ipv6_help": "اجازه دهید از IPv6 برای دریافت و ارسال نامه استفاده شود",
"global_settings_setting_smtp_relay_enabled_help": "میزبان رله SMTP برای ارسال نامه به جای این نمونه yunohost استفاده می شود. اگر در یکی از این شرایط قرار دارید مفید است: پورت 25 شما توسط ارائه دهنده ISP یا VPS شما مسدود شده است، شما یک IP مسکونی دارید که در DUHL ذکر شده است، نمی توانید DNS معکوس را پیکربندی کنید یا این سرور مستقیماً در اینترنت نمایش داده نمی شود و می خواهید از یکی دیگر برای ارسال ایمیل استفاده کنید."
}
}

View file

@ -781,5 +781,12 @@
"log_dyndns_unsubscribe": "Se désabonner d'un sous-domaine YunoHost '{}'",
"dyndns_too_many_requests": "Le service dyndns de YunoHost a reçu trop de requêtes/demandes de votre part, attendez environ 1 heure avant de réessayer.",
"ask_dyndns_recovery_password_explain_unavailable": "Ce domaine DynDNS est déjà enregistré. Si vous êtes la personne qui a enregistré ce domaine lors de sa création, vous pouvez entrer le mot de passe de récupération pour récupérer ce domaine.",
"global_settings_setting_ssh_port_help": "Il est préférable d'utiliser un port inférieur à 1024 pour éviter les tentatives d'usurpation par des services non administrateurs sur la machine distante. Vous devez également éviter d'utiliser un port déjà utilisé tel que le 80 ou le 443."
}
"global_settings_setting_ssh_port_help": "Il est préférable d'utiliser un port inférieur à 1024 pour éviter les tentatives d'usurpation par des services non administrateurs sur la machine distante. Vous devez également éviter d'utiliser un port déjà utilisé tel que le 80 ou le 443.",
"diagnosis_ignore_already_filtered": "(Il y a déjà un filtre de diagnostic {category} qui correspond à ces critères)",
"diagnosis_ignore_no_filter_found": "(Il n'y pas de filtre de diagnostic pour la catégorie {category} qui correspond à ces critères)",
"diagnosis_ignore_filter_added": "Filtre de diagnostic pour {category} ajouté",
"diagnosis_ignore_filter_removed": "Filtre de diagnostic pour {category} supprimé",
"diagnosis_ignore_missing_criteria": "Vous devez fournir au moins un critère qui est une catégorie de diagnostic à ignorer",
"diagnosis_ignore_criteria_error": "Les critères doivent être sous la forme de clé=valeur (ex. domain=yolo.test)",
"diagnosis_ignore_no_issue_found": "Aucun problème correspondant au critère donné n'a été trouvé."
}

View file

@ -782,4 +782,4 @@
"ask_dyndns_recovery_password_explain_unavailable": "Este dominio DynDNS xa está rexistrado. Se es a persoa que o rexistrou orixinalmente, podes escribir o código de recuperación para reclamar o dominio.",
"dyndns_too_many_requests": "O servicio dyndns de YunoHost recibeu demasiadas peticións do teu sistema, agarda 1 hora e volve intentalo.",
"global_settings_setting_ssh_port_help": "É recomendable un porto inferior a 1024 para evitar os intentos de apropiación por parte de servizos de non-administración na máquina remota. Tamén deberías evitar elexir un porto que xa está sendo utilizado, como 80 ou 443."
}
}

View file

@ -441,4 +441,4 @@
"service_enable_failed": "Tidak dapat membuat layanan '{service}' dimulai mandiri saat pemulaian.\n\nLog layanan baru-baru ini:{logs}",
"service_not_reloading_because_conf_broken": "Tidak memuat atau memulai ulang layanan '{name}' karena konfigurasinya rusak: {errors}",
"service_reloaded": "Layanan {service} dimuat ulang"
}
}

View file

@ -668,4 +668,4 @@
"certmanager_cert_renew_failed": "Il rinnovo del certificato Lets Encrypt è fallito per {domains}",
"ask_dyndns_recovery_password_explain": "Scegli una password di recupero per il tuo dominio DynDNS, in caso dovessi ripristinarlo successivamente.",
"confirm_app_insufficient_ram": "PERICOLO! Questapp richiede {required} di RAM per essere installata/aggiornata, ma solo {current} sono disponibili ora. Nonostante lapp possa funzionare, la sua installazione o aggiornamento richiedono una grande quantità di RAM, perciò il tuo server potrebbe bloccarsi o fallire miseramente. Se sei dispostə a prenderti questo rischio comunque, digita {answers}"
}
}

View file

@ -760,4 +760,4 @@
"yunohost_not_installed": "YunoHostが正しくインストールされていません。yunohost tools postinstall を実行してください",
"yunohost_postinstall_end_tip": "インストール後処理が完了しました!セットアップを完了するには、次の点を考慮してください。\n - ウェブ管理画面の'診断'セクション(またはコマンドラインでyunohost diagnosis run)を通じて潜在的な問題を診断します。\n - 管理ドキュメントの'セットアップの最終処理'と'YunoHostを知る'の部分を読む: https://yunohost.org/admindoc。",
"additional_urls_already_removed": "アクセス許可 {permission} に対する追加URLで {url} は既に削除されています"
}
}

View file

@ -328,5 +328,17 @@
"global_settings_setting_smtp_allow_ipv6_help": "Разрешить использование IPv6 для получения и отправки почты",
"admins": "Администраторы",
"all_users": "Все пользователи YunoHost",
"app_action_failed": "Не удалось выполнить действие {action} для приложения {app}"
"app_action_failed": "Не удалось выполнить действие {action} для приложения {app}",
"app_manifest_install_ask_init_main_permission": "Кто должен иметь доступ к этому приложению? (Это может быть изменено позже)",
"app_arch_not_supported": "Это приложение может быть установлено только на архитектуры {required}, но архитектура вашего сервер - {current}",
"app_manifest_install_ask_init_admin_permission": "Кто должен иметь доступ к функциям для администраторов этого приложения? (Это может быть изменено позже)",
"app_change_url_script_failed": "Произошла ошибка внутри скрипта смены URL",
"app_corrupt_source": "YunoHost смог скачать материал «{source_id}» ({url}) для {app}, но материал не соотвествует с ожидаемой контрольной суммой. Это может означать, что на ваше сервере произошла временная сетевая ошибка, ИЛИ материал был каким-либо образом изменён сопровождающим главной ветки (или злоумышленником?) и упаковщикам YunoHost нужно выяснить и, возможно, обновить манифест, чтобы применить изменения.\n Ожидаемая контрольная сумма sha256: {expected_sha256}\n Полученная контрольная сумма sha256: {computed_sha256}\n Размер скачанного файла: {size}",
"app_not_enough_ram": "Это приложение требует {required} ОЗУ для установки/обновления, но сейчас доступно только {current}.",
"app_change_url_failed": "Невозможно изменить URL для {app}: {error}",
"app_not_enough_disk": "Это приложение требует {required} свободного места.",
"app_change_url_require_full_domain": "{app} не может быть перемещено на данный URL, потому что оно требует весь домен (т.е., путь - /)",
"app_failed_to_download_asset": "Не удалось скачать материал «{source_id}» ({url}) для {app}: {out}",
"app_failed_to_upgrade_but_continue": "Не удалось обновить приложение {failed_app}, обновления продолжаются, как запрошено. Выполните «yunohost log show {operation_logger_name}», чтобы увидеть журнал ошибки",
"app_not_upgraded_broken_system": "Не удалось обновить приложение «{failed_app}», система находится в сломанном состоянии, обновления следующих приложений были отменены: {apps}"
}

View file

@ -279,4 +279,4 @@
"domain_config_cert_summary": "Stav certifikátu",
"domain_config_xmpp": "Krátke správy (XMPP)",
"log_app_makedefault": "Nastaviť '{}' ako predvolenú aplikáciu"
}
}

View file

@ -781,4 +781,4 @@
"dyndns_set_recovery_password_failed": "Не вдалося встановити пароль для відновлення: {error}",
"dyndns_set_recovery_password_success": "Пароль для відновлення встановлено!",
"log_dyndns_unsubscribe": "Скасувати підписку на субдомен YunoHost '{}'"
}
}

View file

@ -587,4 +587,4 @@
"ask_admin_fullname": "管理员全名",
"ask_admin_username": "管理员用户名",
"ask_fullname": "全名"
}
}

View file

@ -263,16 +263,12 @@ def _diagnosis_ignore(add_filter=None, remove_filter=None, list=False):
# Sanity checks for the provided arguments
if len(filter_) == 0:
raise YunohostValidationError(
"You should provide at least one criteria being the diagnosis category to ignore"
)
raise YunohostValidationError(m18n.n("diagnosis_ignore_missing_criteria"))
category = filter_[0]
if category not in all_categories_names:
raise YunohostValidationError(f"{category} is not a diagnosis category")
if any("=" not in criteria for criteria in filter_[1:]):
raise YunohostValidationError(
"Criterias should be of the form key=value (e.g. domain=yolo.test)"
)
raise YunohostValidationError(m18n.n("diagnosis_ignore_criteria_error"))
# Convert the provided criteria into a nice dict
criterias = {c.split("=")[0]: c.split("=")[1] for c in filter_[1:]}
@ -295,7 +291,7 @@ def _diagnosis_ignore(add_filter=None, remove_filter=None, list=False):
issue_matches_criterias(i, criterias)
for i in current_issues_for_this_category
):
raise YunohostError("No issues was found matching the given criteria.")
raise YunohostError(m18n.n("diagnosis_ignore_no_issue_found"))
# Make sure the subdicts/lists exists
if "ignore_filters" not in configuration:
@ -305,13 +301,13 @@ def _diagnosis_ignore(add_filter=None, remove_filter=None, list=False):
if criterias in configuration["ignore_filters"][category]:
logger.warning(
f"(There is already a diagnosis {category} filter with these criterias)"
m18n.n("diagnosis_ignore_already_filtered", category=category)
)
return
configuration["ignore_filters"][category].append(criterias)
_diagnosis_write_configuration(configuration)
logger.success(f"Added a {category} diagnosis filter")
logger.success(m18n.n("diagnosis_ignore_filter_added", category=category))
return
if remove_filter:
@ -325,13 +321,13 @@ def _diagnosis_ignore(add_filter=None, remove_filter=None, list=False):
if criterias not in configuration["ignore_filters"][category]:
logger.warning(
f"(There is no such diagnosis {category} filter with these criterias to remove)"
m18n.n("diagnosis_ignore_no_filter_found", category=category)
)
return
configuration["ignore_filters"][category].remove(criterias)
_diagnosis_write_configuration(configuration)
logger.success(f"Removed a {category} diagnosis filter")
logger.success(m18n.n("diagnosis_ignore_filter_removed", category=category))
return

View file

@ -791,7 +791,7 @@ class OperationLogger:
# Get the 20 lines before the last 'ynh_exit_properly'
rev_lines = list(reversed(lines))
for i, line in enumerate(rev_lines):
for i, line in enumerate(rev_lines[:50]):
if line.endswith("+ ynh_exit_properly"):
lines_to_display = reversed(rev_lines[i : i + 20])
break