Lono Concepts

Here are main Lono concepts:

Blueprints

Lono blueprints encapsulate the code used to build CloudFormation templates and infrastructure resources. Blueprints are what you’ll mostly work with and can live in app/blueprints The simplest blueprint struture is:

app/blueprints/demo
└── template.rb

Docs: Blueprints

Params

CloudFormation parameters allow you to create different environments with the same template code. Lono params simplify this process by providing an env-like file syntax. Here’s an example:

config/blueprints/demo/params/dev.env:

KeyName=default
InstanceType=t2.micro

Docs: Params

Variables

Lono Variables allow you to compile down different templates when run-time params do not suffice. This allows doing things that are outside of the ability of CloudFormation run-time parameters. Here’s an example:

config/blueprints/demo/vars/dev.env:

@desc = "Template description"

Docs: Variables

Layering

Lono supports a concept called Layering. Layering allows you to build both prod and dev environments with the same template code. Here’s an simple example of layering:

config/blueprints/demo/params
├── dev.env
└── prod.env

Docs: Layering

Helpers

Helpers methods allow you to extend the Lono DSL. With Custom Helpers you can define your own helper methods. Lono also comes with some built-in helper methods.

Docs: Helpers