Skip to content

yudaiogawa/notify-aws-billing

Repository files navigation

Notify AWS Billing

Serverless Application for notifies AWS billing to slack.


Architecture Image


Requirements

  • awscli
  • docker 19.03.0
  • docker-compose
  • node/npm
  • python 3.8
  • pip
  • pipenv
  • serverless framework
  • slack webhook url

Required Settings

AWS PROFILE

Requires the IAM user granted the AdministratorAccess or the IAM user granted the appropriate permission.

% aws configure --profile foobar

Getting Started - Use Docker

  1. Create .env
  2. Create the docker image n container
  3. Create a new Bash session in the container
  4. Introduction
  5. Invoke

1:

Define the following variables to .env .

  • AWS_PROFILE
  • WEBHOOK_URL

2:

% make up

3:

% make exec

4:

% npm i
% pipenv install -r requirements.txt

5:

% pipenv shell
% make invoke-local

Getting Started - Use Host

  1. Export the environment variables
  2. Introduction
  3. Invoke

1:

% export AWS_PROFILE=foobar
% export WEBHOOK_URL='https://hooks.slack.com/services/T00/B00/XXX'

2:

% npm i
% pipenv install -r requirements.txt

3:

% pipenv shell
% make invoke-local

Deploy

Deploys your entire service:

% make deploy-dev # to development

% make deploy-prd # to production.

Deploys an function:

% make deploy-func-dev # to development

% make deploy-func-prd # to production

Invokes deployed function:

% make invoke-dev # of development

% make invoke-prd # of production

Remove the deployed service

% make rm-dev # from development

% make rm-prd # from production

License

This software is released under the MIT License, see LICENSE.

About

serverless application for notifies AWS billing :)

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published