Skip to content

Commit

Permalink
Merge pull request #9 from plesk/bring-new-changes
Browse files Browse the repository at this point in the history
Bring new changes
  • Loading branch information
SandakovMM authored Oct 30, 2024
2 parents 947d8f8 + 4b11453 commit 2de6057
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions debian11to12/upgrader.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ class Debian11to12Upgrader(DistUpgrader):
_distro_from = dist.Debian("11")
_distro_to = dist.Debian("12")


def __init__(self):
super().__init__()

Expand All @@ -37,7 +36,6 @@ def supports(
and (to_system is None or cls._distro_to == to_system)
)


@property
def upgrader_name(self) -> str:
return "Plesk::Debian11to12Upgrader"
Expand All @@ -59,6 +57,7 @@ def prepare_feedback(
feedback.collect_installed_packages_dpkg,
feedback.collect_apt_policy,
feedback.collect_plesk_version,
feedback.collect_kernel_modules,
]
return feed

Expand All @@ -68,7 +67,7 @@ def construct_actions(
options: typing.Any,
phase: Phase
) -> typing.Dict[str, typing.List[action.ActiveAction]]:
new_os = f"{self._distro_to}"
new_os = str(self._distro_to)
return {
"Prepare": [
actions.HandleConversionStatus(options.status_flag_path, options.completion_flag_path),
Expand Down Expand Up @@ -97,7 +96,7 @@ def construct_actions(
'\g<1>://\g<2>/\g<3>12.7\g<4>',
),
actions.ReplaceAptReposRegexp(
r'(http|https)://([^/]+)/(.*\b)11\(\b.*)',
r'(http|https)://([^/]+)/(.*\b)11(\b.*)',
'\g<1>://\g<2>/\g<3>12\g<4>',
),
actions.SwitchPleskRepositories(to_os_version="12"),
Expand Down Expand Up @@ -139,7 +138,7 @@ def get_check_actions(self, options: typing.Any, phase: Phase) -> typing.List[ac
]

def parse_args(self, args: typing.Sequence[str]) -> None:
DESC_MESSAGE = f"""Use this upgrader to dist-upgrade an {self._distro_from} server with Plesk to {self._distro_to} The process consists of the following general stages:
DESC_MESSAGE = f"""Use this upgrader to dist-upgrade an {self._distro_from} server with Plesk to {self._distro_to}. The process consists of the following general stages:
-- Preparation (about 5 minutes) - The OS is prepared for the conversion.
-- Conversion (about 15 minutes) - Plesk and system dist-upgrade is performed.
Expand Down

0 comments on commit 2de6057

Please sign in to comment.