Merge pull request #9471 from thalesmg/check-unpack-target-v44

fix(install_upgrade): check target version when unpacking (v4.4)
This commit is contained in:
Thales Macedo Garitezi 2022-12-06 13:09:34 -03:00 committed by GitHub
commit 8ad9e7a008
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -32,6 +32,7 @@ main(Args) ->
unpack({RelName, NameTypeArg, NodeName, Cookie}, Opts) -> unpack({RelName, NameTypeArg, NodeName, Cookie}, Opts) ->
TargetNode = start_distribution(NodeName, NameTypeArg, Cookie), TargetNode = start_distribution(NodeName, NameTypeArg, Cookie),
Version = proplists:get_value(version, Opts), Version = proplists:get_value(version, Opts),
validate_target_version(Version, TargetNode),
case unpack_release(RelName, TargetNode, Version) of case unpack_release(RelName, TargetNode, Version) of
{ok, Vsn} -> {ok, Vsn} ->
?INFO("Unpacked successfully: ~p", [Vsn]); ?INFO("Unpacked successfully: ~p", [Vsn]);