Skip to content

Commit

Permalink
Merge pull request #500 from D3vil0p3r/patch-1
Browse files Browse the repository at this point in the history
Add compatMode raw JSON output and fix tls_verify init on pull()
  • Loading branch information
openshift-merge-bot[bot] authored Jan 16, 2025
2 parents c6db9c2 + 4bd2d33 commit b20360f
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions podman/domain/images_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,8 @@ def pull(
auth_config (Mapping[str, str]) – Override the credentials that are found in the
config for this request. auth_config should contain the username and password
keys to be valid.
compatMode (bool) – Return the same JSON payload as the Docker-compat endpoint.
Default: True.
decode (bool) – Decode the JSON data from the server into dicts.
Only applies with ``stream=True``
platform (str) – Platform in the format os[/arch[/variant]]
Expand Down Expand Up @@ -357,7 +359,8 @@ def pull(

params = {
"reference": repository,
"tlsVerify": kwargs.get("tls_verify"),
"tlsVerify": kwargs.get("tls_verify", True),
"compatMode": kwargs.get("compatMode", True),
}

if all_tags:
Expand Down Expand Up @@ -409,7 +412,7 @@ def pull(
if stream:
return self._stream_helper(response, decode=kwargs.get("decode"))

for item in response.iter_lines():
for item in reversed(list(response.iter_lines())):
obj = json.loads(item)
if all_tags and "images" in obj:
images: List[Image] = []
Expand Down

0 comments on commit b20360f

Please sign in to comment.