https://pulumi.com logo
#getting-started
Title
# getting-started
g

gifted-artist-72219

03/03/2022, 7:55 AM
Hi, can anybody explain how switch Event pattern to Pre-defined pattern by service in Amazon EventBridge Rules? Аt now my EventRule looks like this
Copy code
const EventRule = new aws.cloudwatch.EventRule("testpulumi", {
    eventBusName: "default",
    isEnabled: true,
    name: "testpulumi",
    description: "Get scheduled events for EC2 instance",
    eventPattern: `{
      "source": ["aws.health"],
      "detail-type": ["AWS Health Event"],
      "detail": {
        "service": ["EC2"],
        "eventTypeCategory": ["scheduledChange"]
      }
    }`,
});
g

great-queen-39697

03/04/2022, 9:06 PM
that looks fairly reasonable; what error are you getting?
g

gifted-artist-72219

03/07/2022, 7:02 AM
No errors - this case work as should, but - this is example of “Custom pattern”, but i need “Pre-defined pattern by service” and dont known how do this
5 Views