In this video, you’ll see how to integrate your data sources into AWS Systems Manager OpsCenter using Amazon EventBridge.
With this solution, you can set up simple EventBridge rules that monitor events as operational items in OpsCenter,
where on-call operators have tools to investigate and remediate common issues with AWS resources.
To get started, let’s navigate to Systems Manager and take a look at OpsCenter.
OpsCenter aggregates events and alerts across multiple AWS services.
These issues appear in OpsCenter as a standardized form of operational work item known as an “OpsItem.”
Here, you can see all your open OpsItems.
Let’s review the one titled “Issue detected for EC2 infrastructure.”
In the details, we can see which CloudWatch Event Rule triggered the issue as well as the issue’s level of severity.
Here, we can see the specific Amazon Elastic Compute Cloud (Amazon EC2) instance that’s having the issue.
OpsCenter allows us to run automations on OpsItems to resolve problems like this one.
We can choose what we need from the list of AWS provided runbooks.
For instance, we can restart the EC2 instance.
As you can see, the instance successfully restarted, so let’s move on.
Next, let’s navigate to AWS Config to see an example compliance rule we’d like to onboard to OpsCenter.
AWS Config continuously monitors our AWS resources for compliance with our desired configurations.
In this case, we have a rule that specifies a desired instance type.
The parameters show that EC2 instances must either be t2.micro or t2.small.
Now let’s use our Config rule as an example to show how we can automate the creation of OpsItems
for any service that publishes events to Amazon EventBridge.
We’ll create a rule that generates an OpsItem whenever AWS Config detects a non-compliant EC2 instance size.
Here, we’ll specify the event pattern.
Now that we have defined our event, we can see that the event pattern has been updated to reflect that.
Let’s continue creating the rule.
Since we are generating an OpsItem every time this rule is triggered, our target will be SSM OpsItem.
Let’s configure our input.
We’ll select Input transformer so that we can define what information we want the OpsItems to contain.
We will also be able to associate relevant automations.
You can familiarize yourself with the input path schema by referring to the Amazon CloudWatch Events documentation.
Let’s return to our EventBridge rule and specify the input transformer.
Likewise, you can familiarize yourself with the input template schema by referring to the OpsItem API reference documentation.
Let’s go back to the rule and specify the input template.
This is the template we defined.
In it, we've specified key metadata for the OpsItem, such as a title, a description, and priority and severity ratings of "2."
Notice that it includes automations for remediating noncompliance.
Specifying this deduplication string is important to reduce the risk of creating duplicate OpsItems.
Let’s create the rule.
Now let’s take a quick look at the rule.
We can see from our event pattern that our source is AWS Config, that we are specifically looking for compliance changes,
and that the predefined rule is desired-instance-type.
Let’s navigate to EC2 and look at the instance types of our running instances.
As you can see, one of our instances is t2.medium, which falls outside of our compliance definition.
Let’s go to AWS Config to see if it detected this non-compliant instance.
As expected, a non-compliant resource was detected.
Let’s take a closer look.
The details show this particular instance is a t2.medium, which does not conform to our compliance rule.
Let’s navigate back to Systems Manager and take a look at OpsCenter.
Let’s take a look at the newest OpsItem.
The instance was added as a related resource.
As you can see, this OpsItem was generated by our EventBridge rule, which was triggered by AWS Config.
Finally, you can click 'Related resource details' to see all the information for the instance.
The ops team can now investigate this item right from OpsCenter and potentially run an automation to remediate the issue.
You’ve just seen how to integrate your data sources into AWS Systems Manager OpsCenter using Amazon EventBridge.
Thanks for watching.
Now it’s your turn to try.