-
Notifications
You must be signed in to change notification settings - Fork 342
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ec2_vol: Fix incorrectly returned changed result (#483)
ec2_vol: Fix incorrectly returned changed result SUMMARY When modify_volume is used but no new disk is being attached, the module incorrectly reports that no change has occurred even when disks have been modified (iops, throughput, type, etc.). This is due to the attach function overwriting the changed variable even if no disks are attached. Fixes #482 The integration test has been fixed so that when the gp3 modifications are tested, the volume is already in an attached state (previously detached) when reporting back changed. The detach tests are moved further down now, allowing this case to be properly covered by the existing assert: amazon.aws/tests/integration/targets/ec2_vol/tasks/tests.yml Lines 384 to 387 in e8df917 - name: check that volume_type has changed assert: that: - changed_gp3_volume.changed ISSUE TYPE Bugfix Pull Request COMPONENT NAME ec2_vol Reviewed-by: Alina Buzachis <None> Reviewed-by: None <None> Reviewed-by: Mark Chappell <None> Reviewed-by: None <None>
- Loading branch information
Showing
3 changed files
with
31 additions
and
25 deletions.
There are no files selected for viewing
6 changes: 6 additions & 0 deletions
6
changelogs/fragments/483-ec2_vol_fix_returned_changed_var.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
bugfixes: | ||
- >- | ||
ec2_vol - Fixes ``changed`` status when ``modify_volume`` is used, but no new | ||
disk is being attached. The module incorrectly reported that no change had | ||
occurred even when disks had been modified (iops, throughput, type, etc.). | ||
(https://github.com/ansible-collections/amazon.aws/issues/482). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters