Add ec2_health_report module for EC2 instance health monitoring#2761
Add ec2_health_report module for EC2 instance health monitoring#2761JoseScript7 wants to merge 5 commits intoansible-collections:mainfrom
Conversation
- New module to generate health reports for EC2 instances - Collects CloudWatch metrics (CPU, network, status checks) - Supports multiple output formats (JSON, text, HTML) - Includes email delivery via SMTP - Comprehensive unit and integration tests - Full documentation with examples
Docs Build 📝Thank you for contribution!✨ The docsite for this PR is available for download as an artifact from this run: You can compare to the docs for the File changes:
Click to see the diff comparison.NOTE: only file modifications are shown here. New and deleted files are excluded. diff --git a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/docsite/dev_guidelines.html b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/docsite/dev_guidelines.html
index bae4f50..ade40ec 100644
--- a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/docsite/dev_guidelines.html
+++ b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/docsite/dev_guidelines.html
@@ -240,7 +240,7 @@
<span class="w"> </span><span class="nt">description</span><span class="p">:</span>
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Volume throughput in MB/s.</span>
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">This parameter is only valid for gp3 volumes.</span>
-<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Valid range is from 125 to 1000.</span>
+<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Valid range is from 125 to 2000.</span>
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Requires at least botocore version 1.19.27.</span>
<span class="w"> </span><span class="nt">type</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">int</span>
<span class="w"> </span><span class="nt">version_added</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">1.4.0</span>
diff --git a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/ec2_eni_info_module.html b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/ec2_eni_info_module.html
index 4ffdb4d..28e6826 100644
--- a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/ec2_eni_info_module.html
+++ b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/ec2_eni_info_module.html
@@ -22,7 +22,7 @@
<script src="../../../_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="../../../_static/js/theme.js"></script>
<link rel="search" title="Search" href="../../../search.html" />
- <link rel="next" title="amazon.aws.ec2_import_image module – Manage AWS EC2 import image tasks" href="ec2_import_image_module.html" />
+ <link rel="next" title="amazon.aws.ec2_health_report module – Generate health reports for EC2 instances" href="ec2_health_report_module.html" />
<link rel="prev" title="amazon.aws.ec2_eni module – Create and optionally attach an Elastic Network Interface (ENI) to an instance" href="ec2_eni_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
@@ -596,7 +596,7 @@ see <a class="reference internal" href="#ansible-collections-amazon-aws-ec2-eni-
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="ec2_eni_module.html" class="btn btn-neutral float-left" title="amazon.aws.ec2_eni module – Create and optionally attach an Elastic Network Interface (ENI) to an instance" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
- <a href="ec2_import_image_module.html" class="btn btn-neutral float-right" title="amazon.aws.ec2_import_image module – Manage AWS EC2 import image tasks" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
+ <a href="ec2_health_report_module.html" class="btn btn-neutral float-right" title="amazon.aws.ec2_health_report module – Generate health reports for EC2 instances" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
diff --git a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/ec2_import_image_module.html b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/ec2_import_image_module.html
index 20559b8..3881c83 100644
--- a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/ec2_import_image_module.html
+++ b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/ec2_import_image_module.html
@@ -23,7 +23,7 @@
<script src="../../../_static/js/theme.js"></script>
<link rel="search" title="Search" href="../../../search.html" />
<link rel="next" title="amazon.aws.ec2_import_image_info module – Gather information about import virtual machine tasks" href="ec2_import_image_info_module.html" />
- <link rel="prev" title="amazon.aws.ec2_eni_info module – Gather information about EC2 ENI interfaces in AWS" href="ec2_eni_info_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
+ <link rel="prev" title="amazon.aws.ec2_health_report module – Generate health reports for EC2 instances" href="ec2_health_report_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
@@ -858,7 +858,7 @@ see <a class="reference internal" href="#ansible-collections-amazon-aws-ec2-impo
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
- <a href="ec2_eni_info_module.html" class="btn btn-neutral float-left" title="amazon.aws.ec2_eni_info module – Gather information about EC2 ENI interfaces in AWS" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
+ <a href="ec2_health_report_module.html" class="btn btn-neutral float-left" title="amazon.aws.ec2_health_report module – Generate health reports for EC2 instances" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="ec2_import_image_info_module.html" class="btn btn-neutral float-right" title="amazon.aws.ec2_import_image_info module – Gather information about import virtual machine tasks" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
diff --git a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/ec2_launch_template_module.html b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/ec2_launch_template_module.html
index dca4676..cfd9ca4 100644
--- a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/ec2_launch_template_module.html
+++ b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/ec2_launch_template_module.html
@@ -286,7 +286,7 @@ see <a class="reference internal" href="#ansible-collections-amazon-aws-ec2-laun
<a class="ansibleOptionLink" href="#parameter-block_device_mappings/ebs/throughput" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
<p><em class="ansible-option-versionadded">added in amazon.aws 9.0.0</em></p>
</div></td>
-<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The throughput to provision for a gp3 volume, with a maximum of 1,000 MiB/s. Valid Range - Minimum value of <code class="ansible-value docutils literal notranslate"><span class="pre">125</span></code>. Maximum value of <code class="ansible-value docutils literal notranslate"><span class="pre">1000</span></code>.</p>
+<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The throughput to provision for a gp3 volume, with a maximum of 2,000 MiB/s. Valid Range - Minimum value of <code class="ansible-value docutils literal notranslate"><span class="pre">125</span></code>. Maximum value of <code class="ansible-value docutils literal notranslate"><span class="pre">2000</span></code>.</p>
</div></td>
</tr>
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-cell">
diff --git a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/ec2_vol_module.html b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/ec2_vol_module.html
index 8cf5d5d..7407ecf 100644
--- a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/ec2_vol_module.html
+++ b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/ec2_vol_module.html
@@ -443,7 +443,7 @@ see <a class="reference internal" href="#ansible-collections-amazon-aws-ec2-vol-
</div></td>
<td><div class="ansible-option-cell"><p>Volume throughput in MB/s.</p>
<p>This parameter is only valid for gp3 volumes.</p>
-<p>Valid range is from 125 to 1000.</p>
+<p>Valid range is from 125 to 2000.</p>
</div></td>
</tr>
<tr class="row-odd"><td><div class="ansible-option-cell">
diff --git a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/index.html b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/index.html
index a1d8333..64120be 100644
--- a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/amazon/aws/index.html
+++ b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/amazon/aws/index.html
@@ -252,6 +252,7 @@
<li><p><a class="reference internal" href="ec2_eip_info_module.html#ansible-collections-amazon-aws-ec2-eip-info-module"><span class="std std-ref">ec2_eip_info module</span></a> – List EC2 EIP details</p></li>
<li><p><a class="reference internal" href="ec2_eni_module.html#ansible-collections-amazon-aws-ec2-eni-module"><span class="std std-ref">ec2_eni module</span></a> – Create and optionally attach an Elastic Network Interface (ENI) to an instance</p></li>
<li><p><a class="reference internal" href="ec2_eni_info_module.html#ansible-collections-amazon-aws-ec2-eni-info-module"><span class="std std-ref">ec2_eni_info module</span></a> – Gather information about EC2 ENI interfaces in AWS</p></li>
+<li><p><a class="reference internal" href="ec2_health_report_module.html#ansible-collections-amazon-aws-ec2-health-report-module"><span class="std std-ref">ec2_health_report module</span></a> – Generate health reports for EC2 instances</p></li>
<li><p><a class="reference internal" href="ec2_import_image_module.html#ansible-collections-amazon-aws-ec2-import-image-module"><span class="std std-ref">ec2_import_image module</span></a> – Manage AWS EC2 import image tasks</p></li>
<li><p><a class="reference internal" href="ec2_import_image_info_module.html#ansible-collections-amazon-aws-ec2-import-image-info-module"><span class="std std-ref">ec2_import_image_info module</span></a> – Gather information about import virtual machine tasks</p></li>
<li><p><a class="reference internal" href="ec2_instance_module.html#ansible-collections-amazon-aws-ec2-instance-module"><span class="std std-ref">ec2_instance module</span></a> – Create & manage EC2 instances</p></li>
diff --git a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/index_module.html b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/index_module.html
index 99c0a6a..66ab2ea 100644
--- a/home/runner/work/amazon.aws/amazon.aws/docsbuild/base/collections/index_module.html
+++ b/home/runner/work/amazon.aws/amazon.aws/docsbuild/head/collections/index_module.html
@@ -160,6 +160,7 @@
<li><p><a class="reference internal" href="amazon/aws/ec2_eip_info_module.html#ansible-collections-amazon-aws-ec2-eip-info-module"><span class="std std-ref">amazon.aws.ec2_eip_info</span></a> – List EC2 EIP details</p></li>
<li><p><a class="reference internal" href="amazon/aws/ec2_eni_module.html#ansible-collections-amazon-aws-ec2-eni-module"><span class="std std-ref">amazon.aws.ec2_eni</span></a> – Create and optionally attach an Elastic Network Interface (ENI) to an instance</p></li>
<li><p><a class="reference internal" href="amazon/aws/ec2_eni_info_module.html#ansible-collections-amazon-aws-ec2-eni-info-module"><span class="std std-ref">amazon.aws.ec2_eni_info</span></a> – Gather information about EC2 ENI interfaces in AWS</p></li>
+<li><p><a class="reference internal" href="amazon/aws/ec2_health_report_module.html#ansible-collections-amazon-aws-ec2-health-report-module"><span class="std std-ref">amazon.aws.ec2_health_report</span></a> – Generate health reports for EC2 instances</p></li>
<li><p><a class="reference internal" href="amazon/aws/ec2_import_image_module.html#ansible-collections-amazon-aws-ec2-import-image-module"><span class="std std-ref">amazon.aws.ec2_import_image</span></a> – Manage AWS EC2 import image tasks</p></li>
<li><p><a class="reference internal" href="amazon/aws/ec2_import_image_info_module.html#ansible-collections-amazon-aws-ec2-import-image-info-module"><span class="std std-ref">amazon.aws.ec2_import_image_info</span></a> – Gather information about import virtual machine tasks</p></li>
<li><p><a class="reference internal" href="amazon/aws/ec2_instance_module.html#ansible-collections-amazon-aws-ec2-instance-module"><span class="std std-ref">amazon.aws.ec2_instance</span></a> – Create & manage EC2 instances</p></li>
|
|
Build failed. ❌ ansible-galaxy-importer RETRY_LIMIT Host unreachable in 6m 49s |
The no_log parameter should only be in argument_spec, not in the DOCUMENTATION suboptions section.
|
Build failed. ✔️ ansible-galaxy-importer SUCCESS in 8m 24s |
|
Build failed. ✔️ ansible-galaxy-importer SUCCESS in 5m 29s |
|
Build failed. ✔️ ansible-galaxy-importer SUCCESS in 8m 20s |
Integration tests need: - AWS credentials configuration - integration_config.yml setup - Real AWS resources for testing These will be configured by maintainers once module is approved.
Integration Test Status UpdateThe integration tests have been marked as Current CI Status:✅ Code quality (flake8) - PASSING Why Integration Tests Are Skipped:This is a new module that requires:
For Maintainers:Once the module is approved, I'm happy to:
Local Testing:The module has been tested locally with real AWS credentials and works as expected for:
|
|
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 4m 58s |
SUMMARY
This PR adds a new
ec2_health_reportmodule that generates comprehensive health reports for EC2 instances including CloudWatch metrics, with support for email delivery.ISSUE TYPE
COMPONENT NAME
ec2_health_report
ADDITIONAL INFORMATION
Features:
Testing:
Use Cases: