Giter Site home page Giter Site logo

maniacs-oss / modules.tf-lambda Goto Github PK

View Code? Open in Web Editor NEW

This project forked from antonbabenko/modules.tf-lambda

0.0 2.0 0.0 305 KB

Infrastructure as code generator - from visual diagrams created with Cloudcraft.co to Terraform

Home Page: https://cloudcraft.co/app

License: MIT License

Shell 9.69% Python 76.61% HCL 13.70%

modules.tf-lambda's Introduction

modules.tf - Infrastructure as code generator - from visual diagrams to Terraform

MIT license Gitter

modules.tf - Infrastructure as code generator - from visual diagrams to Terraform

This repository contains code for generating infrastructure as code from visual diagrams created in Cloudcraft.

Code in this repository has been already deployed to AWS Lambda and available for all Cloudcraft users for free (forever):

  • Draw your AWS architecture on Cloudcraft
  • Click "Export" and "Export as code (modules.tf)" at the top right side
  • Download archive and unzip it
  • Follow the instructions in README.md file to get resources created on your AWS account.

Supporters

Cloudcraft - the best way to draw AWS diagrams

This project was partially sponsored by Cloudcraft - the best way to draw AWS diagrams.

Monitoring of serverless applications provided by Dashbird.io. Dashbird - Monitor serverless applications

I am developer - show me the code & let's ship it!

Ok, if you are a developer and want to contribute, this is really great because I need your help:

  • Report, triage and fix bugs
  • Refactor code
  • Improve documentation
  • Implement new sources and workflows (now only Cloudcraft is partially supported)
  • Consider contributing to Terraform AWS modules if you familiar with Terraform already

Developer's guide

AWS Lambda supports Python 3.6, so you should use it also. Run this to install all required packages:

$ pip install -r requirements.txt

Serverless framework is used to do heavy-lifting by packaging dependencies required for AWS Lambda function (requirements-lambda.txt) and updating the code there. Read through Quick Start guide, as well as installation, various AWS functions, serverless.yml reference to familiarise yourself with the usage of the framework.

As a short cheatsheet, you will need to use these commands:

  • Invoke real endpoint in dev and prod environments using httpie:
# dev
$ http --print Hhb --all --follow https://dev-lambda.modules.tf/ @input/blueprint_my.json

# prod
$ http --print Hhb --all --follow https://lambda.modules.tf/ @input/blueprint_my.json
  • Invoke function locally providing input.json:
$ serverless invoke local --function generate-cloudcraft --path test_fixtures/input_localfile.json
  • Deploy all functions to prod environment:
$ serverless deploy --stage prod
  • Deploy single function to dev environment:
$ serverless deploy function --function generate-cloudcraft --stage dev
  • Deploy single function to prod environment:
$ serverless deploy function --function generate-cloudcraft --stage prod

Authors

This project is created and maintained by Anton Babenko with the help from different contributors.

@antonbabenko

License

This work is licensed under MIT License. See LICENSE for full details.

Copyright (c) 2019 Anton Babenko

modules.tf-lambda's People

Contributors

antonbabenko avatar ebahsini avatar k0te avatar

Watchers

 avatar  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.