Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add key_data argument to ec2_win_password.py module #45463

Merged
merged 3 commits into from
Oct 17, 2018
Merged

add key_data argument to ec2_win_password.py module #45463

merged 3 commits into from
Oct 17, 2018

Conversation

maxstack
Copy link
Contributor

@maxstack maxstack commented Sep 11, 2018

The key_data argument helps when using a private key stored in Vault.

SUMMARY

This PR relates to the AWS ec2_win_password.py module. We have a use case where we need to decrypt Windows passwords for ec2 instances, the existing module allows you to specify a file path to a private key. Our workspace is not persistent so the private key is not persistent to the filesystem, and we will not store it in SCM as Ansible Vault will not decrypt it on the fly.

I have added a new argument - key_data, to use as an alternative to key_file. You can store your private key in Ansible Vault and pass the variable (eg. "{{ ec2_private_key }}") to this argument for on the fly decryption.

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME

ec2_win_password.py

ANSIBLE VERSION
ansible 2.6.0
  config file = /etc/ansible/ansible.cfg
  configured module search path = [u'/var/lib/jenkins/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
  ansible python module location = /var/lib/jenkins/workspace/ansible_test/ec2_win_venv/lib/python2.7/site-packages/ansible
  executable location = /var/lib/jenkins/workspace/ansible_test/ec2_win_venv/bin/ansible
  python version = 2.7.5 (default, Aug  2 2016, 04:20:16) [GCC 4.8.5 20150623 (Red Hat 4.8.5-4)]
ADDITIONAL INFORMATION

The key_data argument helps when using a private key stored in Vault.
@ansibot
Copy link
Contributor

ansibot commented Sep 11, 2018

@ansibot
Copy link
Contributor

ansibot commented Sep 11, 2018

Hi @maxstack,

Thank you for the pullrequest, just so you are aware we have a dedicated Working Group for aws.
You can find other people interested in this in #ansible-aws on Freenode IRC
For more information about communities, meetings and agendas see https://github.com/ansible/community

click here for bot help

@ansibot ansibot added affects_2.8 This issue/PR affects Ansible v2.8 aws cloud community_review In order to be merged, this PR must follow the community review workflow. feature This issue/PR relates to a feature request. module This issue/PR relates to a module. needs_triage Needs a first human triage before being processed. new_contributor This PR is the first contribution by a new community member. support:community This issue/PR relates to code supported by the Ansible community. labels Sep 11, 2018
@maxstack maxstack changed the title add key_data argument add key_data argument to ec2_win_password.py module Sep 11, 2018
Add version_added line to pass automated tests.
@webknjaz webknjaz removed the needs_triage Needs a first human triage before being processed. label Sep 11, 2018
@ansibot ansibot added core_review In order to be merged, this PR must follow the core review workflow. support:core This issue/PR relates to code supported by the Ansible Engineering Team. and removed community_review In order to be merged, this PR must follow the community review workflow. support:community This issue/PR relates to code supported by the Ansible community. labels Sep 19, 2018
@ansibot ansibot added the stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. label Sep 28, 2018
@ansibot ansibot added community_review In order to be merged, this PR must follow the community review workflow. needs_maintainer Ansibot is unable to identify maintainers for this PR. (Check `author` in docs or BOTMETA.yml) support:community This issue/PR relates to code supported by the Ansible community. and removed core_review In order to be merged, this PR must follow the core review workflow. support:core This issue/PR relates to code supported by the Ansible Engineering Team. labels Oct 6, 2018
@ryansb ryansb merged commit c11aba6 into ansible:devel Oct 17, 2018
Tomorrow9 pushed a commit to Tomorrow9/ansible that referenced this pull request Dec 4, 2018
* add key_data argument

The key_data argument helps when using a private key stored in Vault.

* Add "version_added" line

Add version_added line to pass automated tests.

* remove unnecessary nesting
@ansible ansible locked and limited conversation to collaborators Jul 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.8 This issue/PR affects Ansible v2.8 aws cloud community_review In order to be merged, this PR must follow the community review workflow. feature This issue/PR relates to a feature request. module This issue/PR relates to a module. needs_maintainer Ansibot is unable to identify maintainers for this PR. (Check `author` in docs or BOTMETA.yml) new_contributor This PR is the first contribution by a new community member. stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. support:community This issue/PR relates to code supported by the Ansible community.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants