From 23f1275aa70931df93e832ecfeb243c303a036d3 Mon Sep 17 00:00:00 2001 From: Paul Lecuq Date: Sat, 1 Oct 2022 20:13:01 +0200 Subject: [PATCH] updated apt state --- states/apt/apt.py.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/states/apt/apt.py.j2 b/states/apt/apt.py.j2 index febece1..1b8d029 100755 --- a/states/apt/apt.py.j2 +++ b/states/apt/apt.py.j2 @@ -10,7 +10,7 @@ PORT = "{{ apt.proxy.port }}" def main(): regex = re.compile(f".*{HOSTNAME}.*") - cmd = subprocess.Popen(f"avahi-resolve-host-name {HOSTNAME}", + cmd = subprocess.Popen(f"getent hosts {HOSTNAME}", shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)