Skip to content

Instantly share code, notes, and snippets.

@sirech
Last active November 6, 2020 14:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sirech/e25d7bda16627a6a60101aab6def3a45 to your computer and use it in GitHub Desktop.
Save sirech/e25d7bda16627a6a60101aab6def3a45 to your computer and use it in GitHub Desktop.
from diagrams import Diagram, Cluster
from diagrams.aws.storage import S3
from diagrams.aws.compute import Lambda
from diagrams.aws.integration import SNS, Eventbridge
from diagrams.aws.management import Cloudwatch
from diagrams.onprem.queue import ActiveMQ
with Diagram("Alerting Workflow", show=True):
with Cluster('main account'):
topic = SNS('SNS Topic')
with Cluster('Lambda'):
l = Lambda('processor')
topic >> l
S3('lambda source') - l
cl = Cloudwatch('Cloudwatch')
l >> cl
event = Eventbridge('Cloudwatch\nevent rule')
cl >> event
with Cluster('Event Bus'):
event_bus = ActiveMQ('bus')
event >> event_bus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment