Skip to content

feat(medialive): add Elemental MediaLive modules to community collection - #2318

Closed
buxell wants to merge 11 commits into
ansible-collections:mainfrom
buxell:github-integration-emla
Closed

feat(medialive): add Elemental MediaLive modules to community collection#2318
buxell wants to merge 11 commits into
ansible-collections:mainfrom
buxell:github-integration-emla

Conversation

@buxell

@buxell buxell commented Jun 12, 2025

Copy link
Copy Markdown
SUMMARY

Adds new modules for AWS Elemental MediaLive to enable infrastructure-as-code management of MediaLive resources. These modules support automation of MediaLive configurations including Elemental Anywhere (bring-your-own-device) setups.

The following modules are included in this PR:

  • medialive_sdi_source
  • medialive_node
  • medialive_network
  • medialive_input
  • medialive_cluster
  • medialive_channel
  • medialive_channel_placement_group
ISSUE TYPE
  • New Module Pull Request
COMPONENT NAME

aws.medialive

ADDITIONAL INFORMATION

These modules expand the AWS collection's coverage to include MediaLive services, particularly useful for organizations managing broadcast and streaming workflows through Ansible automation.

Testing completed:

  • Integration tests added for each module
  • Tested with Python 3.x
  • Documentation includes examples for all modules
  • Change logs updated
  • Module arguments documented with type hints and descriptions
  • Return values documented for all modules

Contributors:

@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/3cf1e84dd356459dad7d8d68729c7b99

ansible-galaxy-importer FAILURE in 3m 37s (non-voting)
✔️ build-ansible-collection SUCCESS in 11m 05s
✔️ ansible-test-splitter SUCCESS in 4m 20s
integration-community.aws-1 FAILURE in 5m 57s
integration-community.aws-2 FAILURE in 6m 16s
integration-community.aws-3 FAILURE in 5m 17s
integration-community.aws-4 FAILURE in 9m 57s
integration-community.aws-5 FAILURE in 5m 20s
integration-community.aws-6 FAILURE in 9m 13s
Skipped 16 jobs

@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/5d4284ef96974fb4bf0b4701893391ee

ansible-galaxy-importer FAILURE in 3m 51s (non-voting)
✔️ build-ansible-collection SUCCESS in 11m 16s
✔️ ansible-test-splitter SUCCESS in 4m 29s
integration-community.aws-1 FAILURE in 6m 02s
integration-community.aws-2 FAILURE in 7m 03s
integration-community.aws-3 FAILURE in 11m 45s
integration-community.aws-4 FAILURE in 6m 07s
integration-community.aws-5 FAILURE in 11m 45s
integration-community.aws-6 FAILURE in 5m 16s
Skipped 16 jobs

@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/0bfb042121644652a5641b7a915141ef

✔️ ansible-galaxy-importer SUCCESS in 4m 35s (non-voting)
✔️ build-ansible-collection SUCCESS in 11m 07s
✔️ ansible-test-splitter SUCCESS in 4m 17s
integration-community.aws-1 FAILURE in 6m 10s
integration-community.aws-2 FAILURE in 6m 18s
integration-community.aws-3 FAILURE in 5m 20s
integration-community.aws-4 FAILURE in 6m 12s
integration-community.aws-5 FAILURE in 5m 20s
integration-community.aws-6 FAILURE in 5m 11s
Skipped 16 jobs

@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/85e98565244e494fada601170ae2a408

ansible-galaxy-importer FAILURE in 3m 40s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 54s
✔️ ansible-test-splitter SUCCESS in 4m 17s
integration-community.aws-1 FAILURE in 6m 46s
integration-community.aws-2 FAILURE in 7m 37s
integration-community.aws-3 FAILURE in 5m 33s
integration-community.aws-4 FAILURE in 6m 02s
integration-community.aws-5 FAILURE in 6m 38s
integration-community.aws-6 FAILURE in 5m 17s
Skipped 16 jobs

@buxell

buxell commented Jul 14, 2025

Copy link
Copy Markdown
Author

I'm seeing two issues with this PR:

  1. Documentation build failure - unclear from logs what's causing this, and I notice similar failures in other recent PRs.
  2. Integration test failures in CI - I've confirmed these tests pass locally using an IAM role with the required MediaLive permissions. Looking for guidance on how to update the CI environment's IAM role to include these permissions, if that is needed.

I've also asked for guidance in the #ansible-aws channel in Libera to help move this forward.

@gundalow

Copy link
Copy Markdown
Contributor

@buxell If you rebase your PR, then the Documentation build failures should be fixed.

The forum post you created is the best place to get help with the IAM permissions

@buxell
buxell force-pushed the github-integration-emla branch from b4233e0 to b360ae5 Compare July 18, 2025 17:37
@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

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

✔️ ansible-galaxy-importer SUCCESS in 4m 56s (non-voting)
✔️ build-ansible-collection SUCCESS in 11m 10s
✔️ ansible-test-splitter SUCCESS in 4m 15s
integration-community.aws-1 FAILURE in 8m 07s
integration-community.aws-2 FAILURE in 8m 21s
integration-community.aws-3 FAILURE in 7m 21s
integration-community.aws-4 FAILURE in 8m 29s
integration-community.aws-5 FAILURE in 6m 39s
integration-community.aws-6 FAILURE in 6m 35s
Skipped 16 jobs

Adds new modules for AWS Elemental MediaLive management:
- medialive_sdi_source: Manage SDI source configurations
- medialive_node: Handle node operations
- medialive_network: Configure network settings
- medialive_input: Manage input configurations
- medialive_cluster: Control cluster operations
- medialive_channel_placement_group: Manage channel placement groups

This enhancement enables comprehensive management of MediaLive resources
through Ansible automation, supporting bring-your-own-device Elemental
Anywhere systems.

Co-authored-by: Sergey Papyan <spapyan@amazon.com>
Co-authored-by: David Teach <dteach@amazon.com>
Co-authored-by: Brenton Buxell <buxell@amazon.com>
@buxell
buxell force-pushed the github-integration-emla branch from b360ae5 to 4628e9a Compare July 18, 2025 21:56
@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

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

ansible-galaxy-importer FAILURE in 3m 35s (non-voting)
✔️ build-ansible-collection SUCCESS in 11m 00s
✔️ ansible-test-splitter SUCCESS in 4m 12s
integration-community.aws-1 FAILURE in 6m 12s
integration-community.aws-2 FAILURE in 12m 43s
integration-community.aws-3 FAILURE in 5m 28s
integration-community.aws-4 FAILURE in 15m 43s
integration-community.aws-5 FAILURE in 5m 07s
integration-community.aws-6 FAILURE in 11m 56s
Skipped 16 jobs

@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/6142b3edcf7a4cd98c477380bc9934dc

✔️ ansible-galaxy-importer SUCCESS in 4m 05s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 55s
✔️ ansible-test-splitter SUCCESS in 4m 16s
integration-community.aws-1 FAILURE in 13m 33s
integration-community.aws-2 FAILURE in 13m 31s
integration-community.aws-3 FAILURE in 5m 28s
integration-community.aws-4 FAILURE in 6m 27s
integration-community.aws-5 FAILURE in 5m 20s
integration-community.aws-6 FAILURE in 5m 29s
Skipped 16 jobs

@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

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

ansible-galaxy-importer FAILURE in 4m 15s (non-voting)
✔️ build-ansible-collection SUCCESS in 11m 33s
✔️ ansible-test-splitter SUCCESS in 4m 30s
integration-community.aws-1 FAILURE in 6m 07s
integration-community.aws-2 FAILURE in 6m 16s
integration-community.aws-3 FAILURE in 5m 53s
integration-community.aws-4 FAILURE in 7m 28s
integration-community.aws-5 FAILURE in 5m 35s
integration-community.aws-6 FAILURE in 6m 35s
Skipped 16 jobs

@buxell

buxell commented Jul 29, 2025

Copy link
Copy Markdown
Author

I have created a companion PR in the aws.terminator repository that adds the required MediaLive IAM permissions needed for these integration tests to pass. Once that PR is merged, the CI failures here should be resolved.

mattclay/aws-terminator#315

This PR should now be ready for review.

@alinabuzachis alinabuzachis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@buxell Thank you for your impressive contribution. Would it make sense to you to split this PR into several ones to make the review process easier?

@@ -0,0 +1,3 @@
minor_changes:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For new modules you not need changelog fragments, so, please remove these.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed

Comment thread plugins/modules/medialive_channel.py Outdated
options:
cdi_input_specification:
description:
- Specification of CDI inputs for this channel

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Specification of CDI inputs for this channel
- Specification of CDI inputs for this channel.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Comment thread plugins/modules/medialive_channel.py Outdated
suboptions:
resolution:
description:
- Maximum CDI input resolution

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Maximum CDI input resolution
- Maximum CDI input resolution.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Comment thread plugins/modules/medialive_channel.py Outdated
suboptions:
password_param:
description:
- key used to extract the password from EC2 Parameter store

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- key used to extract the password from EC2 Parameter store
- Key used to extract the password from EC2 Parameter store.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Comment thread plugins/modules/medialive_channel.py Outdated
type: str
stream_name:
description:
- Stream name for RTMP destinations (URLs of type rtmp://)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Stream name for RTMP destinations (URLs of type rtmp://)
- Stream name for RTMP destinations (URLs of type rtmp://).

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Comment thread plugins/modules/medialive_channel.py Outdated
suboptions:
password_param:
description:
- key used to extract the password from EC2 Parameter store

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- key used to extract the password from EC2 Parameter store
- Key used to extract the password from EC2 Parameter store.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Comment thread plugins/modules/medialive_channel.py Outdated
- 'DVBDASH_7_CLEAN_FEED'
feature_activations:
description:
- Feature Activations

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Feature Activations
- Feature Activations.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Comment thread plugins/modules/medialive_channel.py Outdated
suboptions:
black_frame_msec:
description:
- Documentation update needed

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Documentation update needed
- Documentation update needed.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

class MediaLiveWaiterFactory(BaseWaiterFactory):
'''Custom waiter factory for MediaLive channel placement group resources'''

@property

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got rid of custom waiters in favor of official ones

)


def do_update_channel(self, params):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it make sense to move some of the shared logic to a plugins/modules_utils/medialive.py file?

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe there isn't enough shared logic to make it worth it

@softwarefactory-project-zuul

Copy link
Copy Markdown
Contributor

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

ansible-galaxy-importer FAILURE in 3m 41s (non-voting)
✔️ build-ansible-collection SUCCESS in 11m 06s
✔️ ansible-test-splitter SUCCESS in 4m 25s
integration-community.aws-1 RETRY_LIMIT in 3m 19s
integration-community.aws-2 RETRY_LIMIT in 3m 17s
integration-community.aws-3 RETRY_LIMIT in 3m 19s
integration-community.aws-4 RETRY_LIMIT in 4m 16s
integration-community.aws-5 RETRY_LIMIT in 3m 19s
integration-community.aws-6 RETRY_LIMIT in 3m 59s
Skipped 16 jobs

@r363x

r363x commented Aug 19, 2025

Copy link
Copy Markdown

@buxell Thank you for your impressive contribution. Would it make sense to you to split this PR into several ones to make the review process easier?

Hi @alinabuzachis. I am one of the contributors and I've taken over the shepherding of this PR from @buxell.
To answer your question, we would prefer not to split the PR unless you think it is necessary, as:

  • there is clear separation between the modules BUT
  • many of the modules depend on other modules (from this PR) for their integration tests

@r363x

r363x commented Aug 19, 2025

Copy link
Copy Markdown

On a different note - could you possibly take a look at this PR as well, @alinabuzachis? I believe I've seen you review older PRs on mattclay/aws-terminator, and this one takes care of adding the necessary IAM permissions for the integration tests here to succeed.

@buxell

buxell commented Oct 29, 2025

Copy link
Copy Markdown
Author

Closing this in favor of #2353

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants