GithubHelp home page GithubHelp logo

isabella232 / cfn-s3-public-access-block-provider Goto Github PK

View Code? Open in Web Editor NEW

This project forked from binxio/cfn-s3-public-access-block-provider

0.0 0.0 0.0 13 KB

License: Apache License 2.0

Shell 18.51% JavaScript 12.39% Python 16.10% Makefile 53.00%

cfn-s3-public-access-block-provider's Introduction

cfn-s3-public-access-block

Custom CloudFormation resource to enable S3 Public Access Blocks.

Please refer to the links below to lean the features (more secure) and limitations this provides.

After cloning this directory you have to following make targets at your command:

make                    - builds a zip file to target/.
make test               - execute the tests, requires a working AWS connection.

make deploy             - deploy to the default region eu-central-1.
make deploy-all-regions - deploy to all regions.

make release            - builds a zip file and deploys it to s3.

make deploy-provider    - deploys the provider.
make delete-provider    - deletes the provider.

make demo               - deploys the demo cloudformation stack.
make delete-demo        - deletes the demo cloudformation stack.

make clean              - the workspace.

Pre-requisites

You need to have awscli, python, jq and Docker installed.

Getting started

this template contains all the stuff to create, test and deploy a simple Custom Resource provider for the resource Custom::Custom.

The idea is that the resource just copies the property Value to return it as an atttribute of the CFN resource. To experience a complete development cycle, you need to implement the create, update and delete methods in src/cfn_custom_provider.py until the following command succeeds:

make test

The source implements a ResourceProvider class defined by Python module cfn_resource_provider.

Deploying the provider

Set the variable S3_BUCKET_PREFIX and AWS_REGION in the Makefile to point to your bucket (See #S3 buckets for details).

After that succeeds, deploy the provider by typing:

make deploy
make deploy-provider

Deploying the demo

After the provider is deployed, you can create the demo stack:

make demo

Now you are ready to create useful Custom CloudFormation Providers!

Checkout Kong API Gateway, Secrets and SES for example.

S3 Buckets

To deploy your lambda to all AWS regions, you need to have s3 buckets in all regions matching the name pattern:

   <s3-bucket-prefix>-<aws-region>

For the development cycle, you need to have at least a bucket in your default region, for instance binxio-public-eu-central-1.

To ease the creation of all buckets, you could use the create-global-s3-buckets script.

cfn-s3-public-access-block-provider's People

Contributors

tader avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.