mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-06-30 07:50:43 +00:00
More shell updates
This commit is contained in:
parent
e7f74251c8
commit
4e8b97ddeb
4 changed files with 19 additions and 15 deletions
|
|
@ -286,7 +286,7 @@ class FedoraStrategy(GenericStrategy):
|
|||
|
||||
def get_permanent_hostname(self):
|
||||
cmd = 'hostnamectl status | awk \'/^ *Static hostname:/{printf("%s", $3)}\''
|
||||
rc, out, err = self.module.run_command(cmd)
|
||||
rc, out, err = self.module.run_command(cmd, use_unsafe_shell=True)
|
||||
if rc != 0:
|
||||
self.module.fail_json(msg="Command failed rc=%d, out=%s, err=%s" %
|
||||
(rc, out, err))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue