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

EIP items should allow tagging. #331

Closed
JonTheNiceGuy opened this issue Dec 11, 2020 · 1 comment · Fixed by #332
Closed

EIP items should allow tagging. #331

JonTheNiceGuy opened this issue Dec 11, 2020 · 1 comment · Fixed by #332
Assignees
Labels
feature This issue/PR relates to a feature request has_pr

Comments

@JonTheNiceGuy
Copy link

SUMMARY

While it's possible to create an EIP (with community.aws.ec2_eip) and then tag it (with community.aws.ec2_tag), it would be much more useful and concise to make it so that ec2_eip would also permit you to tag the object.

ISSUE TYPE
  • Feature Idea
COMPONENT NAME

community.aws.ec2_eip

ADDITIONAL INFORMATION

Currently you need to do this:

- hosts: localhost
  gather_facts: false
  tasks:
  - community.aws.ec2_eip:
      region: "{{ item.region }}"
      device_id: "{{ item.device_id }}"
      private_ip_address: "{{ item.private_ip_address }}"
      state: present
      in_vpc: true
    register: ec2_allocation
    loop: [{'name': 'demo_eip', 'region': 'eu-west-1', 'device_id': 'eni-01234567890abcdef', 'private_ip': '192.0.2.15'}]
  - amazon.aws.ec2_tag:
      region: "{{ item.invocation.module_args.region }}"
      resource: "{{ item.allocation_id }}"
      state: present
      tags:
        Name: "{{ item.item.name }}"
    loop: "{{ ec2_allocation.results }}"

It would be better if you could do this:

- hosts: localhost
  gather_facts: false
  tasks:
  - community.aws.ec2_eip:
      region: eu-west-1
      device_id: eni-01234567890abcdef
      private_ip_address: 192.0.2.15
      tags:
        Name: demo_eip
      state: present
      in_vpc: true
@tremble tremble self-assigned this Dec 11, 2020
@tremble tremble mentioned this issue Dec 11, 2020
3 tasks
@ansibullbot
Copy link

Files identified in the description:
None

If these files are inaccurate, please update the component name section of the description or use the !component bot command.

click here for bot help

@ansibullbot ansibullbot added feature This issue/PR relates to a feature request has_pr labels Jan 13, 2021
ansible-zuul bot pushed a commit that referenced this issue Oct 17, 2021
ec2_eip tagging support

SUMMARY
Add support for tagging EIPs on creation.
Todo:

 EIP Tagging
 Tests
 Retry decorator

Note: While it's now possible to pass tagging information into the association call this was only added Dec 2020 so won't work for most folks.
ISSUE TYPE

Feature Pull Request

COMPONENT NAME
ec2_eip
ec2_eip_info
ADDITIONAL INFORMATION
fixes: #331

Reviewed-by: Rick Mendes <None>
Reviewed-by: None <None>
alinabuzachis pushed a commit to alinabuzachis/community.aws that referenced this issue May 25, 2022
abikouo pushed a commit to abikouo/community.aws that referenced this issue Oct 24, 2023
…_contrib_script_compatible_ec2_tag_keys (ansible-collections#858)

Add version_added: 1.5.0 for exclude_filters, include_filters and use_contrib_script_compatible_ec2_tag_keys

SUMMARY

Add version_added: 1.5.0 for exclude_filters, include_filters and use_contrib_script_compatible_ec2_tag_keys
include_filters and exclude_filters have been added ansible-collections#328 and released with amazon.aws 1.5.0
use_contrib_script_compatible_ec2_tag_keys has been added ansible-collections#331 and released with  amazon.aws 1.5.0
Let's update the aws_ec2 inventory plugin documentation with this information.
This should be a step towards closing this one ansible-collections#676 and ansible-collections#675
aws_ec2 documentation will be enriched with exhaustive examples in an upcoming PR.

ISSUE TYPE


Docs Pull Request

COMPONENT NAME

aws_ec2
ADDITIONAL INFORMATION

Reviewed-by: Mark Chappell <None>
abikouo pushed a commit to abikouo/community.aws that referenced this issue Oct 24, 2023
ec2_eip tagging support

SUMMARY
Add support for tagging EIPs on creation.
Todo:

 EIP Tagging
 Tests
 Retry decorator

Note: While it's now possible to pass tagging information into the association call this was only added Dec 2020 so won't work for most folks.
ISSUE TYPE

Feature Pull Request

COMPONENT NAME
ec2_eip
ec2_eip_info
ADDITIONAL INFORMATION
fixes: ansible-collections#331

Reviewed-by: Rick Mendes <None>
Reviewed-by: None <None>

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections@02836f3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature This issue/PR relates to a feature request has_pr
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants