Skip to content

Commit

Permalink
Fix systemctl status may hang when redirected to pager (less)
Browse files Browse the repository at this point in the history
  • Loading branch information
lpramuk authored and rplevka committed May 20, 2019
1 parent 9274cc3 commit 2bcb9b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion automation_tools/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -611,7 +611,7 @@ def setup_firewall(definitions=None, flush=True):
else:
if run('rpm -q firewalld', quiet=True).failed:
run('yum install -y firewalld')
if run('systemctl status firewalld', quiet=True).failed:
if run('systemctl --no-pager status firewalld', quiet=True).failed:
run('systemctl enable firewalld')
run('systemctl start firewalld')
exists_command = 'firewall-cmd --permanent --query-port="{1}/{0}"'
Expand Down

0 comments on commit 2bcb9b3

Please sign in to comment.