From ab4f02b5ad5ff1aefd3e973284d36fd867fa1e34 Mon Sep 17 00:00:00 2001 From: Mikhail Sandakov Date: Thu, 29 Aug 2024 14:19:09 +0300 Subject: [PATCH] fixup! fixup! fixup! Add an action to support legacy PHP debian and ubuntu repositories --- pleskdistup/actions/distupgrade.py | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/pleskdistup/actions/distupgrade.py b/pleskdistup/actions/distupgrade.py index 919ea4d..b7b01bc 100644 --- a/pleskdistup/actions/distupgrade.py +++ b/pleskdistup/actions/distupgrade.py @@ -68,23 +68,21 @@ def estimate_revert_time(self) -> int: return 0 -class UpdateLegacyPHPRepositories(action.ActiveAction): +class UpdateLegacyPhpRepositories(action.ActiveAction): legacy_php_versions_inf3_urls: typing.List[str] from_os: dist.Distro to_os: dist.Distro sources_list_d_path: str def __init__( - self, - from_os: dist.Distro, - to_os: dist.Distro, - sources_list_d_path: str = "/etc/apt/sources.list.d/", + self, + from_os: dist.Distro, + to_os: dist.Distro, + sources_list_d_path: str = "/etc/apt/sources.list.d/", ): self.name = "update legacy PHP repositories" self.legacy_php_versions_inf3_urls = [ - "https://autoinstall.plesk.com/php71.inf3", - "https://autoinstall.plesk.com/php72.inf3", - "https://autoinstall.plesk.com/php73.inf3", + "https://autoinstall.plesk.com/php{}.inf3".format(version) for version in [71, 72, 73] ] self.from_os = from_os self.to_os = to_os