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

Promote iam_group module #1755

Conversation

mandar242
Copy link
Contributor

SUMMARY

Migrate iam_group module from community.aws

related to ansible-collections/community.aws#1945

ISSUE TYPE
  • Bugfix Pull Request
  • Docs Pull Request
  • Feature Pull Request
  • New Module Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION

jillr and others added 22 commits September 13, 2023 12:43
* Rename core collection

Rename references to ansible.amazon to amazon.aws.

* Rename community.amazon to community.aws
Fix pep8 line lengths for rewritten amazon.aws imports

* Missed a path in shippable.sh
* Dependency repos moved

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@235c5db
* Remove ANSIBLE_METADATA entirely, see ansible/ansible/pull/69454.
Remove `license` field from galaxy.yml, in favor of `license_file`.

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@05672a6
* Update docs

Remove .git from repo url so links in readme will generate correctly
Add required ansible version
Run latest version of add_docs.py
Add version_added string to modules

* galaxy.yml was missing authors

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@96ee268
* Reorder imports
* Make use of is_boto3_error_message
* Mass-migration over to is_boto3_error_code
* Remove unused imports
* unused vars in exception
* Improve consistency around catching BotoCoreError and ClientError
* Remove unused imports
* Remove unused 'PolicyError' from iam_policy_info
* Avoid catching botocore.exceptions.ClientError when we only want some error codes
* Import camel_dict_to_snake_dict/snake_dict_to_camel_dict from ansible.module_utils.common.dict_transformations

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@4cf52ef
ansible-collections#411)

Add some additional comments so we know *why* the various tests aren't running.  Looks like most of them just need policy updates

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@0d24559
Integration test dependency cleanup

SUMMARY

remove dependencies on setup_remote_tmp_dir where it's not used (often just copy & paste from another test)
remove setup_ec2 (no main.yml means it's not doing anything)
remove prepare_tests (empty main.yml means it's not doing anything)

ISSUE TYPE

Feature Pull Request

COMPONENT NAME
tests/integration/targets
ADDITIONAL INFORMATION
By cleaning up what we have we reduce the chance of people copying things about "because that's what test XYZ did".

Reviewed-by: Alina Buzachis <None>
Reviewed-by: Mark Woolley <[email protected]>

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@dd12046
…#1539)

Make example AWS UUIDS follow a specific pattern

SUMMARY
Various AWS IAM resources have UUID which follow a specific pattern.  Similarly AWS accounts are all 12 digit numbers (text aliases in a couple of cases).  To minimize the risk of accidental data leaks use a consistent Account ID in examples (123456789012), and a specific format for the UUIDS: (AKIA|AGPA|AIDA|AROA|AIPA|ANPA|ANVA|ASIA)12345EXAMPLE54321
While this does nothing about historic data, having consistency makes it easier to prevent future leaks.
Note: We should follow this up with an update to the developer docs, however I'd like to get this in prior to 5.0.0
ISSUE TYPE

Docs Pull Request

COMPONENT NAME
plugins/modules/acm_certificate_info.py
plugins/modules/application_autoscaling_policy.py
plugins/modules/autoscaling_launch_config.py
plugins/modules/autoscaling_launch_config_info.py
plugins/modules/codecommit_repository.py
plugins/modules/directconnect_link_aggregation_group.py
plugins/modules/dms_endpoint.py
plugins/modules/dynamodb_table.py
plugins/modules/ec2_transit_gateway_info.py
plugins/modules/ec2_transit_gateway_vpc_attachment.py
plugins/modules/ec2_transit_gateway_vpc_attachment_info.py
plugins/modules/ec2_vpc_peer.py
plugins/modules/ec2_vpc_peering_info.py
plugins/modules/ec2_vpc_vpn_info.py
plugins/modules/ecs_cluster.py
plugins/modules/ecs_ecr.py
plugins/modules/ecs_service.py
plugins/modules/ecs_service_info.py
plugins/modules/ecs_task.py
plugins/modules/efs.py
plugins/modules/efs_info.py
plugins/modules/eks_cluster.py
plugins/modules/elasticache_subnet_group.py
plugins/modules/elb_network_lb.py
plugins/modules/elb_target_group.py
plugins/modules/elb_target_group_info.py
plugins/modules/elb_target_info.py
plugins/modules/iam_group.py
plugins/modules/iam_managed_policy.py
plugins/modules/iam_mfa_device_info.py
plugins/modules/iam_server_certificate_info.py
plugins/modules/lightsail.py
plugins/modules/lightsail_static_ip.py
plugins/modules/msk_cluster.py
plugins/modules/s3_bucket_notification.py
plugins/modules/sns_topic.py
plugins/modules/sns_topic_info.py
plugins/modules/sqs_queue.py
plugins/modules/stepfunctions_state_machine.py
plugins/modules/stepfunctions_state_machine_execution.py
plugins/modules/storagegateway_info.py
plugins/modules/wafv2_web_acl.py
ADDITIONAL INFORMATION
While the 'secret' nature of these UUIDs is debatable (they're closer to user names than passwords), deliberately mangling them makes it easier for InfoSec teams to spot when their secret counterparts may have been leaked in combination with a real 'public' part.

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@9476422
…collections#1459)

Update extends_documentation_fragment with amazon.aws.boto3

Depends-On: ansible/ansible-zuul-jobs#1654
SUMMARY

As per ansible-collections#985 add amazon.aws.boto3.

ISSUE TYPE

Docs Pull Request

COMPONENT NAME

several

Reviewed-by: Jill R <None>
Reviewed-by: Mark Chappell <None>
Reviewed-by: Markus Bergholz <[email protected]>

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@bd3c03f
Fix non-matching defaults in docs

Depends-On: ansible-collections#1579
SUMMARY
Fix various non-matching default values exposed by ansible/ansible#79267.
ISSUE TYPE

Docs Pull Request

COMPONENT NAME
various

Reviewed-by: Markus Bergholz <[email protected]>

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@15568f0
…ons#1632)

Ansible User-Agent identification for community.aws

SUMMARY

The value will be similar to this APN/1.0 Ansible/2.14.1 community.aws/6.0.0-dev0

ISSUE TYPE

Feature Pull Request

Reviewed-by: Mark Chappell <None>
Reviewed-by: Bikouo Aubin <None>
Reviewed-by: Alina Buzachis <None>

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@a8cbce2
Cleanup headers and imports

SUMMARY
Mass update of imports, docs fragments and file headers

Many of the amazon.aws module_utils and docs fragments got moved about, update community.aws to reflect this.
Consistently apply the comment headers as documented at https://docs.ansible.com/ansible/devel/dev_guide/developing_modules_documenting.html#python-shebang-utf-8-coding

ISSUE TYPE

Docs Pull Request
Feature Pull Request

COMPONENT NAME
ADDITIONAL INFORMATION
Header cleanup based upon:
https://docs.ansible.com/ansible/devel/dev_guide/developing_modules_documenting.html#python-shebang-utf-8-coding

Begin your Ansible module with #!/usr/bin/python - this “shebang” allows ansible_python_interpreter to work. Follow the shebang immediately with # -*- coding: utf-8 -*- to clarify that the file is UTF-8 encoded.

and
https://docs.ansible.com/ansible/devel/dev_guide/developing_modules_documenting.html#copyright-and-license

After the shebang and UTF-8 coding, add a copyright line with the original copyright holder and a license declaration. The license declaration should be ONLY one line, not the full GPL prefix.
...
Additions to the module (for instance, rewrites) are not permitted to add additional copyright lines other than the default copyright statement if missing:

Reviewed-by: Alina Buzachis

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@a4f20bf
* Black prep

* Black

* changelog

* Fix pylint unused-import in tests

* Split SSM connection plugin changes

* disable glue tests - bucket's missing

* Disable s3_logging and s3_sync tests

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@2c4575c
Bulk migration to Python 3.6 f-strings

SUMMARY
We've dropped support for Python <3.6, bulk migrate to fstrings and perform some general string cleanup
A combination of

black --preview
flynt
some manual cleanup

ISSUE TYPE

Feature Pull Request

COMPONENT NAME
plugins/
tests/
ADDITIONAL INFORMATION

Reviewed-by: Alina Buzachis

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@de33821
Various ARN handling fixes

Depends-On: ansible-collections#1619
SUMMARY
fixes: ansible-collections#1846
Various modules had hard-coded ARN handling which assumed the use of the main  partition.  This causes problems for folks using Gov Cloud (and aws-cn)
ISSUE TYPE

Bugfix Pull Request

COMPONENT NAME
plugins/modules/batch_compute_environment.py
plugins/modules/ec2_launch_template.py
plugins/modules/elasticache_info.py
plugins/modules/iam_group.py
plugins/modules/iam_role.py
plugins/modules/msk_config.py
plugins/modules/redshift.py
plugins/modules/sns_topic.py
ADDITIONAL INFORMATION

Reviewed-by: Alina Buzachis

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@25a636c
…ollections#1921)

Mass update of docs and tests (credentials/session tokens)

SUMMARY
We had a cleanup of credentials/session parameters which included a batch of deprecations and renames.
Ensure that all of our tests and docs are using the 'canonical' names
ISSUE TYPE

Docs Pull Request

COMPONENT NAME
plugins/modules/batch_compute_environment.py
plugins/modules/cloudformation_exports_info.py
plugins/modules/ec2_vpc_vpn.py
plugins/modules/elasticache.py
plugins/modules/elasticache_parameter_group.py
plugins/modules/elasticache_snapshot.py
plugins/modules/ses_rule_set.py
plugins/modules/sts_assume_role.py
plugins/modules/sts_session_token.py
tests/integration
ADDITIONAL INFORMATION
See also

ansible-collections#1172
ansible-collections#1714

Reviewed-by: Alina Buzachis

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@4a5b50e
@github-actions
Copy link

github-actions bot commented Sep 13, 2023

Docs Build 📝

Thank you for contribution!✨

This PR has been merged and your docs changes will be incorporated when they are next published.

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/3e64d49dcafc4d3eaa1c9d909dfc33ee

✔️ ansible-galaxy-importer SUCCESS in 4m 42s
✔️ build-ansible-collection SUCCESS in 12m 46s
✔️ ansible-test-splitter SUCCESS in 4m 50s
✔️ integration-amazon.aws-1 SUCCESS in 6m 40s
✔️ integration-amazon.aws-2 SUCCESS in 6m 24s
✔️ integration-amazon.aws-3 SUCCESS in 6m 18s
✔️ integration-community.aws-1 SUCCESS in 6m 24s
Skipped 40 jobs

@softwarefactory-project-zuul
Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/7dcbe7bead414025b7022ab316d17ccb

✔️ ansible-galaxy-importer SUCCESS in 4m 26s
✔️ build-ansible-collection SUCCESS in 13m 08s
✔️ ansible-test-splitter SUCCESS in 4m 37s
✔️ integration-amazon.aws-1 SUCCESS in 6m 32s
✔️ integration-amazon.aws-2 SUCCESS in 6m 42s
integration-amazon.aws-3 RETRY_LIMIT in 1m 43s
✔️ integration-community.aws-1 SUCCESS in 6m 46s
Skipped 40 jobs

@mandar242
Copy link
Contributor Author

recheck

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/03fa0cf468a14dfa8d443465da004cef

✔️ ansible-galaxy-importer SUCCESS in 4m 00s
✔️ build-ansible-collection SUCCESS in 12m 31s
✔️ ansible-test-splitter SUCCESS in 4m 37s
✔️ integration-amazon.aws-1 SUCCESS in 7m 27s
✔️ integration-amazon.aws-2 SUCCESS in 6m 43s
✔️ integration-amazon.aws-3 SUCCESS in 7m 20s
✔️ integration-community.aws-1 SUCCESS in 6m 52s
Skipped 40 jobs

@mandar242 mandar242 added the mergeit Merge the PR (SoftwareFactory) label Sep 15, 2023
@mandar242
Copy link
Contributor Author

regate

@mandar242 mandar242 added mergeit Merge the PR (SoftwareFactory) and removed mergeit Merge the PR (SoftwareFactory) labels Sep 18, 2023
@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/0370724485924326adeeb77009fc376e

✔️ ansible-galaxy-importer SUCCESS in 5m 13s
✔️ build-ansible-collection SUCCESS in 12m 47s
✔️ ansible-test-splitter SUCCESS in 5m 30s
✔️ integration-amazon.aws-1 SUCCESS in 6m 47s
✔️ integration-amazon.aws-2 SUCCESS in 6m 20s
✔️ integration-amazon.aws-3 SUCCESS in 6m 28s
✔️ integration-community.aws-1 SUCCESS in 9m 00s
Skipped 40 jobs

@gravesm gravesm added mergeit Merge the PR (SoftwareFactory) and removed mergeit Merge the PR (SoftwareFactory) labels Sep 18, 2023
@softwarefactory-project-zuul
Copy link
Contributor

Build failed (gate pipeline). For information on how to proceed, see
http://docs.openstack.org/infra/manual/developers.html#automated-testing

https://ansible.softwarefactory-project.io/zuul/buildset/40c11632504541a8b171badaf36ddce9

✔️ ansible-galaxy-importer SUCCESS in 4m 20s
✔️ build-ansible-collection SUCCESS in 12m 25s
✔️ ansible-test-splitter SUCCESS in 4m 38s
integration-amazon.aws-1 RETRY_LIMIT in 1m 42s
✔️ integration-amazon.aws-2 SUCCESS in 6m 46s
✔️ integration-amazon.aws-3 SUCCESS in 6m 55s
✔️ integration-community.aws-1 SUCCESS in 8m 34s
Skipped 40 jobs

@mandar242
Copy link
Contributor Author

regate

@softwarefactory-project-zuul
Copy link
Contributor

Build failed (gate pipeline). For information on how to proceed, see
http://docs.openstack.org/infra/manual/developers.html#automated-testing

https://ansible.softwarefactory-project.io/zuul/buildset/a542ac7280f54a85bdbe644f0beb72f2

✔️ ansible-galaxy-importer SUCCESS in 4m 23s
✔️ build-ansible-collection SUCCESS in 12m 33s
✔️ ansible-test-splitter SUCCESS in 4m 40s
✔️ integration-amazon.aws-1 SUCCESS in 7m 43s
integration-amazon.aws-2 RETRY_LIMIT in 1m 45s
✔️ integration-amazon.aws-3 SUCCESS in 7m 39s
integration-community.aws-1 RETRY_LIMIT in 1m 44s
Skipped 40 jobs

@mandar242 mandar242 added mergeit Merge the PR (SoftwareFactory) and removed mergeit Merge the PR (SoftwareFactory) labels Sep 18, 2023
@softwarefactory-project-zuul
Copy link
Contributor

Build failed (gate pipeline). For information on how to proceed, see
http://docs.openstack.org/infra/manual/developers.html#automated-testing

https://ansible.softwarefactory-project.io/zuul/buildset/7a2c85542e824b239f6e2754541466e1

ansible-galaxy-importer RETRY_LIMIT in 6m 57s
✔️ build-ansible-collection SUCCESS in 12m 56s
✔️ ansible-test-splitter SUCCESS in 4m 40s
✔️ integration-amazon.aws-1 SUCCESS in 7m 37s
✔️ integration-amazon.aws-2 SUCCESS in 7m 11s
✔️ integration-amazon.aws-3 SUCCESS in 7m 59s
✔️ integration-community.aws-1 SUCCESS in 8m 15s
Skipped 40 jobs

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/cc9dd450ce1c4416ac714de89943d0ee

✔️ ansible-galaxy-importer SUCCESS in 4m 59s
✔️ build-ansible-collection SUCCESS in 12m 31s
✔️ ansible-test-splitter SUCCESS in 5m 02s
✔️ integration-amazon.aws-1 SUCCESS in 7m 04s
✔️ integration-amazon.aws-2 SUCCESS in 6m 54s
✔️ integration-amazon.aws-3 SUCCESS in 6m 51s
✔️ integration-community.aws-1 SUCCESS in 7m 26s
Skipped 40 jobs

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded (gate pipeline).
https://ansible.softwarefactory-project.io/zuul/buildset/79bf0d096baa4306aee06654694d0158

✔️ ansible-galaxy-importer SUCCESS in 3m 46s
✔️ build-ansible-collection SUCCESS in 12m 55s
✔️ ansible-test-splitter SUCCESS in 4m 45s
✔️ integration-amazon.aws-1 SUCCESS in 8m 03s
✔️ integration-amazon.aws-2 SUCCESS in 6m 02s
✔️ integration-amazon.aws-3 SUCCESS in 13m 49s
✔️ integration-community.aws-1 SUCCESS in 7m 24s
Skipped 40 jobs

@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit dbb569c into ansible-collections:main Sep 19, 2023
34 of 36 checks passed
softwarefactory-project-zuul bot pushed a commit to ansible-collections/community.aws that referenced this pull request Sep 20, 2023
Promote iam_group module

SUMMARY


Remove iam_group modules and tests
These modules have been migrated to amazon.aws
Update runtime.yml with redirects to that collection
Update ignore files


related to ansible-collections/amazon.aws#1755
ISSUE TYPE


Bugfix Pull Request
Docs Pull Request
Feature Pull Request
New Module Pull Request

COMPONENT NAME

ADDITIONAL INFORMATION

Reviewed-by: Mark Chappell
Reviewed-by: Helen Bailey <[email protected]>
Reviewed-by: Bikouo Aubin
Reviewed-by: Alina Buzachis
alinabuzachis added a commit to alinabuzachis/amazon.aws that referenced this pull request Oct 6, 2023
alinabuzachis added a commit to alinabuzachis/amazon.aws that referenced this pull request Oct 6, 2023
gravesm pushed a commit that referenced this pull request Oct 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mergeit Merge the PR (SoftwareFactory)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants