Coder Social home page Coder Social logo

matwolbec / terraforge Goto Github PK

View Code? Open in Web Editor NEW

This project forked from badarsebard/terraforge

0.0 0.0 0.0 2.2 MB

Graphical Terraform configuration generator

Home Page: https://www.terraforge.tf

License: Mozilla Public License 2.0

JavaScript 43.31% HTML 0.59% Dockerfile 0.22% SCSS 5.23% Svelte 50.65%

terraforge's Introduction

Terraforge is an application for generating Terraform code visually. Users select providers and then add resources as nodes to a graph that can be edited and arranged. Links between nodes appear automatically as the configuration of a node makes references to other nodes. When finished the design can be exported as Terraform HCL. The configuration will include all settings and configurations entered for the nodes.

Terraforge Example

Background

Terraform is a tool for managing infrastructure and APIs in a codified manner utilizing a combination of a command-line application, a series of vendor specific plugins, and a declarative configuration language written in HCL. The configuration uses a flat file structure with layers of abstraction attained through local and remote modules. Writing Terraform configurations create many complex relationships between resources since each resource may rely on attributes of others.

The Terraform application generates a Directed Acyclic Graph (DAG) based on the configuration which establishes the correct order of resource manipulation. There are several tools that allow users to input configuration files then output and visualize the DAG. However, there seems to be a lack of any tool that can reverse this process, starting with a visual representation of the desired infrastructure and exporting the Terraform code. This was the inspiration for Terraforge.

Get started

Running the App

Install the dependencies...

git clone https://github.com/badarsebard/terraforge.git
cd terraforge
npm install

...then start Rollup:

npm run dev

Navigate to localhost:5000. You should see the app running.

Using the App

To get started right away use the Wizard under the Providers menu.

  • Select the Official and AWS checkboxes in the modal and click Submit. Providers Modal
  • Select the hashicorp/aws provider from the dropdown on the right and choose either resource or data source radio buttons.
  • Double-click an entry to add a node of that type to the graph in the center of the page. Create Rsource
  • Click a node to open a pane on the left-hand side of the window where the name and attributes of the node can be modified. Edit Node
  • References between nodes can be made by entering $type.name.attributes in the attribute; e.g.$aws_lb.front_end.arn. Create Edge
  • After creating and editing some resources, export the Terraform configuration by using Export in the HCL menu. Export HCL
  • The browser will download a file called terraforge.tf which will contain the Terraform configuration represented by the diagram and based on the configurations entered.
resource "aws_lb" "front_end" {}
resource "aws_lb_listener" "https" {
  load_balancer_arn = aws_lb.front_end.arn
}

Please note that the app is unable to, at this time, execute any Terraform commands so the output is unformatted and unvalidated.

Documentation

Learn about managing the available providers and how resources and data sources are added.

See all the details about the editor and its components.

Save and load work using design import and export.

Turn your graph into a Terraform config by exporting HCL or pick up with an existing project using the import feature.

See the roadmap for a list of planned features.

License

The majority of this project is licensed under the Mozilla Public License, v. 2.0. The contrib/ directory and its contents are licensed under the MIT license. Any file which does not contain the MPL license header is still covered by the MPL if it is located in a directory containing a LICENSE with the header.

terraforge's People

Contributors

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