mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Revert "The onedir repo.json
files should contain only full versions. Not just major."
This reverts commit 48e084d0f1
.
This commit is contained in:
parent
e948a82012
commit
0302fef43a
1 changed files with 7 additions and 4 deletions
|
@ -1102,7 +1102,8 @@ def release(ctx: Context, salt_version: str):
|
|||
try:
|
||||
ret = s3.head_object(Bucket=bucket_name, Key=path)
|
||||
ctx.info(
|
||||
f"Downloading existing '{repo_file_path.relative_to(repo_path)}' file from bucket {bucket_name}"
|
||||
f"Downloading existing '{repo_file_path.relative_to(repo_path)}' "
|
||||
f"file from bucket {bucket_name}"
|
||||
)
|
||||
size = ret["ContentLength"]
|
||||
with repo_file_path.open("wb") as wfh:
|
||||
|
@ -1543,7 +1544,8 @@ def _create_onedir_based_repo(
|
|||
)
|
||||
minor_versions = [v for v in versions if v.major == major_version]
|
||||
ctx.info(
|
||||
f"Collected versions(Matching major: {major_version}) from {minor_repo_json_path.relative_to(repo_path)}: "
|
||||
f"Collected versions(Matching major: {major_version}) from "
|
||||
f"{minor_repo_json_path.relative_to(repo_path)}: "
|
||||
f"{', '.join(str(vs) for vs in minor_versions)}"
|
||||
)
|
||||
if not versions:
|
||||
|
@ -1577,7 +1579,7 @@ def _create_onedir_based_repo(
|
|||
minor_repo_json["latest"] = release_json
|
||||
# This is the latest minor, update the major in the top level repo.json
|
||||
# to this version
|
||||
repo_json[str(salt_version)] = release_json
|
||||
repo_json[str(major_version)] = release_json
|
||||
ctx.info(f"Creating '{major_link.relative_to(repo_path)}' symlink ...")
|
||||
if major_link.exists():
|
||||
major_link.unlink()
|
||||
|
@ -1608,7 +1610,8 @@ def _get_repo_json_file_contents(
|
|||
Bucket=bucket_name, Key=str(repo_json_path.relative_to(repo_path))
|
||||
)
|
||||
ctx.info(
|
||||
f"Downloading existing '{repo_json_path.relative_to(repo_path)}' file from bucket {bucket_name}"
|
||||
f"Downloading existing '{repo_json_path.relative_to(repo_path)}' file "
|
||||
f"from bucket {bucket_name}"
|
||||
)
|
||||
size = ret["ContentLength"]
|
||||
with repo_json_path.open("wb") as wfh:
|
||||
|
|
Loading…
Add table
Reference in a new issue