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

[PR #1059/a11e66a1 backport][stable-3] iam_user - stabilize for migration to amazon.aws #1120

Conversation

patchback[bot]
Copy link

@patchback patchback bot commented May 5, 2022

This is a backport of PR #1059 as merged into main (a11e66a).

SUMMARY

Stabilize for migration to amazon.aws

  • dont delete user login profile on check mode
  • add extra return value user to deprecate iam_user
  • gracefully handle iam_user_info when no users returned
ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME

iam_user

iam_user - stabilize for migration to amazon.aws

SUMMARY
Stabilize for migration to amazon.aws

dont delete user login profile on check mode
add extra return value user to deprecate iam_user
gracefully handle iam_user_info when no users returned

ISSUE TYPE

Feature Pull Request

COMPONENT NAME
iam_user

Reviewed-by: Mark Chappell <None>
Reviewed-by: Joseph Torcasso <None>
Reviewed-by: Jill R <None>
Reviewed-by: Markus Bergholz <[email protected]>
Reviewed-by: Alina Buzachis <None>
Reviewed-by: Mark Woolley <[email protected]>
Reviewed-by: Mike Graves <[email protected]>
(cherry picked from commit a11e66a)
@ansibullbot
Copy link

@ansibullbot ansibullbot added community_review feature This issue/PR relates to a feature request integration tests/integration module module needs_triage new_contributor Help guide this first time contributor plugins plugin (any type) tests tests labels May 5, 2022
@softwarefactory-project-zuul
Copy link
Contributor

Build failed.

ansible-galaxy-importer FAILURE in 4m 30s (non-voting)
✔️ build-ansible-collection SUCCESS in 4m 57s
ansible-test-sanity-docker-devel FAILURE in 10m 40s (non-voting)
ansible-test-sanity-docker-milestone FAILURE in 10m 37s
✔️ ansible-test-sanity-docker-stable-2.9 SUCCESS in 11m 03s
✔️ ansible-test-sanity-docker-stable-2.11 SUCCESS in 10m 21s
✔️ ansible-test-sanity-docker-stable-2.12 SUCCESS in 10m 03s
✔️ ansible-test-units-community-aws-python38 SUCCESS in 7m 09s
✔️ ansible-test-splitter SUCCESS in 2m 59s
✔️ integration-community.aws-1 SUCCESS in 5m 41s
⚠️ integration-community.aws-2 SKIPPED
⚠️ integration-community.aws-3 SKIPPED
⚠️ integration-community.aws-4 SKIPPED
⚠️ integration-community.aws-5 SKIPPED
⚠️ integration-community.aws-6 SKIPPED
⚠️ integration-community.aws-7 SKIPPED
⚠️ integration-community.aws-8 SKIPPED
⚠️ integration-community.aws-9 SKIPPED
⚠️ integration-community.aws-10 SKIPPED
⚠️ integration-community.aws-11 SKIPPED
⚠️ integration-community.aws-12 SKIPPED
⚠️ integration-community.aws-13 SKIPPED

@alinabuzachis
Copy link
Contributor

recheck

@softwarefactory-project-zuul
Copy link
Contributor

Build failed.

ansible-galaxy-importer FAILURE in 5m 12s (non-voting)
✔️ build-ansible-collection SUCCESS in 5m 33s
ansible-test-sanity-docker-devel FAILURE in 11m 10s (non-voting)
ansible-test-sanity-docker-milestone FAILURE in 9m 33s
✔️ ansible-test-sanity-docker-stable-2.9 SUCCESS in 11m 52s
✔️ ansible-test-sanity-docker-stable-2.11 SUCCESS in 10m 05s
✔️ ansible-test-sanity-docker-stable-2.12 SUCCESS in 11m 42s
✔️ ansible-test-units-community-aws-python38 SUCCESS in 7m 23s
✔️ ansible-test-splitter SUCCESS in 2m 51s
✔️ integration-community.aws-1 SUCCESS in 6m 09s
⚠️ integration-community.aws-2 SKIPPED
⚠️ integration-community.aws-3 SKIPPED
⚠️ integration-community.aws-4 SKIPPED
⚠️ integration-community.aws-5 SKIPPED
⚠️ integration-community.aws-6 SKIPPED
⚠️ integration-community.aws-7 SKIPPED
⚠️ integration-community.aws-8 SKIPPED
⚠️ integration-community.aws-9 SKIPPED
⚠️ integration-community.aws-10 SKIPPED
⚠️ integration-community.aws-11 SKIPPED
⚠️ integration-community.aws-12 SKIPPED
⚠️ integration-community.aws-13 SKIPPED

@jatorcasso
Copy link
Contributor

recheck

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.

ansible-galaxy-importer FAILURE in 5m 00s (non-voting)
✔️ build-ansible-collection SUCCESS in 4m 22s
✔️ ansible-test-sanity-docker-devel SUCCESS in 11m 55s (non-voting)
✔️ ansible-test-sanity-docker-milestone SUCCESS in 11m 23s
✔️ ansible-test-sanity-docker-stable-2.9 SUCCESS in 12m 11s
✔️ ansible-test-sanity-docker-stable-2.11 SUCCESS in 9m 54s
✔️ ansible-test-sanity-docker-stable-2.12 SUCCESS in 9m 41s
✔️ ansible-test-units-community-aws-python38 SUCCESS in 6m 59s
✔️ ansible-test-splitter SUCCESS in 5m 36s
✔️ integration-community.aws-1 SUCCESS in 6m 42s
⚠️ integration-community.aws-2 SKIPPED
⚠️ integration-community.aws-3 SKIPPED
⚠️ integration-community.aws-4 SKIPPED
⚠️ integration-community.aws-5 SKIPPED
⚠️ integration-community.aws-6 SKIPPED
⚠️ integration-community.aws-7 SKIPPED
⚠️ integration-community.aws-8 SKIPPED
⚠️ integration-community.aws-9 SKIPPED
⚠️ integration-community.aws-10 SKIPPED
⚠️ integration-community.aws-11 SKIPPED
⚠️ integration-community.aws-12 SKIPPED
⚠️ integration-community.aws-13 SKIPPED

@markuman markuman added the mergeit Merge the PR (SoftwareFactory) label May 6, 2022
@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded (gate pipeline).

ansible-galaxy-importer FAILURE in 5m 03s (non-voting)
✔️ build-ansible-collection SUCCESS in 4m 56s
✔️ ansible-test-sanity-docker-devel SUCCESS in 11m 25s (non-voting)
✔️ ansible-test-sanity-docker-milestone SUCCESS in 10m 02s
✔️ ansible-test-sanity-docker-stable-2.9 SUCCESS in 14m 21s
✔️ ansible-test-sanity-docker-stable-2.11 SUCCESS in 10m 08s
✔️ ansible-test-sanity-docker-stable-2.12 SUCCESS in 11m 51s
✔️ ansible-test-units-community-aws-python38 SUCCESS in 8m 27s
✔️ ansible-test-splitter SUCCESS in 3m 02s
✔️ integration-community.aws-1 SUCCESS in 5m 44s
⚠️ integration-community.aws-2 SKIPPED
⚠️ integration-community.aws-3 SKIPPED
⚠️ integration-community.aws-4 SKIPPED
⚠️ integration-community.aws-5 SKIPPED
⚠️ integration-community.aws-6 SKIPPED
⚠️ integration-community.aws-7 SKIPPED
⚠️ integration-community.aws-8 SKIPPED
⚠️ integration-community.aws-9 SKIPPED
⚠️ integration-community.aws-10 SKIPPED
⚠️ integration-community.aws-11 SKIPPED
⚠️ integration-community.aws-12 SKIPPED
⚠️ integration-community.aws-13 SKIPPED

@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit 4bf05ca into stable-3 May 6, 2022
@softwarefactory-project-zuul softwarefactory-project-zuul bot deleted the patchback/backports/stable-3/a11e66a1586b3af7f3c35268c60d419d8b023f33/pr-1059 branch May 6, 2022 17:09
abikouo pushed a commit to abikouo/community.aws that referenced this pull request Oct 24, 2023
…collections#1150)

ec2_instance: fix to handle create instance in specified AZ

SUMMARY

This PR adds a fix to allow launching an instance in specified AZ when vpc_subnet_id is not specified.
The current code does not consider the AZ and launches the instance in default subnet of default vpc for the specified region.
https://github.com/ansible-collections/amazon.aws/blob/main/plugins/modules/ec2_instance.py#L1584-L1593

Fixes ansible-collections#1120
ISSUE TYPE


Bugfix Pull Request

COMPONENT NAME

ec2_instance
ADDITIONAL INFORMATION


Without the fix, the below playbook will launch instance in default subnet ignoring specified AZ.
Example Playbook to launch instance in us-west-2b AZ.

---
- name: Spin up ec2 instance
  hosts: localhost
  gather_facts: false
  tasks:
    - name: Launch regular ec2 instances in us-west-1b
      amazon.aws.ec2_instance:
        name: "test-instance-us-west-1b"
        instance_type: t2.micro
        image_id: ami-xxxxx
        state: present
        availability_zone: us-west-1b
        region: us-west-1
        tags:
          terminate-this: yes
        network:
          assign_public_ip: yes
      register: create_result

    - ec2_instance_info:
        instance_ids:
          - "{{ create_result.instance_ids[0] }}"
        region: us-west-1
      register: info_result
    - assert:
        that: info_result.instances[0].placement.availability_zone == 'us-west-1b'

Reviewed-by: Mike Graves <[email protected]>
Reviewed-by: Gonéri Le Bouder <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community_review feature This issue/PR relates to a feature request integration tests/integration mergeit Merge the PR (SoftwareFactory) module module new_contributor Help guide this first time contributor plugins plugin (any type) tests tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants