Skip to content

Commit

Permalink
feat(contrib/terraform): support custom ssh port (kubernetes-sigs#9836)
Browse files Browse the repository at this point in the history
  • Loading branch information
maxime1907 authored and pedromcpedro committed May 8, 2024
1 parent 0de09d6 commit 2787c4b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion contrib/terraform/terraform.py
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,9 @@ def openstack_host(resource, module_name):

# attrs specific to Ansible
if 'metadata.ssh_user' in raw_attrs:
attrs['ansible_ssh_user'] = raw_attrs['metadata.ssh_user']
attrs['ansible_user'] = raw_attrs['metadata.ssh_user']
if 'metadata.ssh_port' in raw_attrs:
attrs['ansible_port'] = raw_attrs['metadata.ssh_port']

if 'volume.#' in list(raw_attrs.keys()) and int(raw_attrs['volume.#']) > 0:
device_index = 1
Expand Down

0 comments on commit 2787c4b

Please sign in to comment.