Skip to content

Commit

Permalink
Update podman version and demux handler to reflect changes in
Browse files Browse the repository at this point in the history
  • Loading branch information
tpapaioa authored and JacobCallahan committed Sep 20, 2024
1 parent 6b88e8e commit 0bf360c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions broker/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
import yaml

from broker import exceptions, logger as b_log, settings
from broker.binds.containers import demux_output

FilterTest = namedtuple("FilterTest", "haystack needle test")
INVENTORY_LOCK = threading.Lock()
Expand Down Expand Up @@ -574,12 +573,13 @@ def from_ssh(cls, stdout, channel):
def from_duplexed_exec(cls, duplex_exec, runtime=None):
"""Create a Result object from a duplexed exec object from podman or docker."""
if runtime == "podman":
stdout, stderr = demux_output(duplex_exec[1])
status, (stdout, stderr) = duplex_exec
return cls(
status=duplex_exec[0],
status=status,
stdout=stdout.decode("utf-8"),
stderr=stderr.decode("utf-8"),
)

if duplex_exec.output[0]:
stdout = duplex_exec.output[0].decode("utf-8")
else:
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ docker = [
"docker",
"paramiko"
]
podman = ["podman"]
podman = ["podman>=5.2"]
setup = [
"build",
"twine",
Expand Down

0 comments on commit 0bf360c

Please sign in to comment.