Public | Automated Build

Last pushed: a year ago
Short Description
The simple sns to webhook service. listens to a specific sns topic and posts to a webhook.
Full Description


The simple sns to webhook service. listens to a specific sns topic and posts to a webhook. The application will expect that a topic exists and will create a SQS queue and subscribe the SNS topic to it automatically. It will also add the policy to the SQS queue automatically if the config user is allowed to add permissions to a SQS policies


IAM Policy Requirements

The following policy Requirements were used for this application credentials:

  • AmazonSQSFullAccess
  • AmazonSNSFullAccess

The Config File

It is expected that the name of the file is


Installing the Virtual Environment

A virtual environment installer is provided called

$ bash ./
$ source ../ve-sns-webhook/bin/activate

Running The Application Locally

$ python --config ~/config/local/
INFO       2017-03-29 15:29:50,529 _new_conn                            735 : Starting new HTTPS connection (1):
INFO       2017-03-29 15:29:50,724 _new_conn                            735 : Starting new HTTPS connection (1):

Using the Docker Container

Building the Container

if you have problems use the --no-cache option

docker build -t dronzebot/snswebhook:latest .

Running The Docker image

The container will use the configuration and brain graph you provide.

$ docker run -t -d -p 5020:5020 --name snswebhook -v ${CONFIG_DIR}:/mnt/config dronzebot/snswebhook:latest

Pushing the Container to AWS ECR

1) Retrieve the docker login command that you can use to authenticate your Docker client to your registry:

aws ecr get-login --region us-west-2

2) Run the docker login command that was returned in the previous step.
3) Build your Docker image using the following command. For information on building a Docker file from scratch see the instructions here. You can skip this step if your image is already built:

docker build -t dronzebot/snswebhook:latest .

4) After the build completes, tag your image so you can push the image to this repository:

docker tag dronzebot/snswebhook:latest

5) Run the following command to push this image to your newly created AWS repository:

docker push

Pulling the Container from the Private Repo and Running

1) login

aws ecr get-login --region us-west-2

2) pull the container from the ecs repo

docker pull

3) make sure that the is in the config dir to be mounted.

4) make sure any existing instances are stoped and removed

$ sudo docker stop snswebhook
$ sudo docker rm snswebhook

5) run it

$ export CONFIG_DIR=/home/ubuntu/config
$ docker run -t -d --name snswebhook -v ${CONFIG_DIR}:/mnt/config
Docker Pull Command
Source Repository