Skip to content

Commit

Permalink
ovirt_host: add ssh_port (#60)
Browse files Browse the repository at this point in the history
  • Loading branch information
mnecas committed Jun 16, 2020
1 parent 300b248 commit 44e9c32
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions plugins/modules/ovirt_host.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@
password:
description:
- "Password of the root. It's required in case C(public_key) is set to I(False)."
ssh_port:
description:
- "The host SSH port."
type: int
public_key:
description:
- "I(True) if the public key should be used to authenticate to host."
Expand Down Expand Up @@ -318,8 +322,9 @@ def build_entity(self):
address=self.param('address'),
root_password=self.param('password'),
ssh=otypes.Ssh(
authentication_method=otypes.SshAuthenticationMethod.PUBLICKEY,
) if self.param('public_key') else None,
authentication_method=otypes.SshAuthenticationMethod.PUBLICKEY if self.param('public_key') else None,
port=self.param('ssh_port'),
),
spm=otypes.Spm(
priority=self.param('spm_priority'),
) if self.param('spm_priority') else None,
Expand Down Expand Up @@ -467,6 +472,7 @@ def main():
comment=dict(default=None),
cluster=dict(default=None),
address=dict(default=None),
ssh_port=dict(default=None, type='int'),
password=dict(default=None, no_log=True),
public_key=dict(default=False, type='bool', aliases=['ssh_public_key']),
kdump_integration=dict(default=None, choices=['enabled', 'disabled']),
Expand Down

0 comments on commit 44e9c32

Please sign in to comment.