Bricks Manifest File Format (bricks.json)

bricks.json is a metadata file used in Atomic Infrastructure™ orchestration.

Every blueprint must have a bricks.json file in its root directory that lists important information about the structure and behavior of that blueprint.

This page explains the structure of the blueprint manifest and the features they can include.

Examples

The following example manifests show the basic manifest structure and some commonly used features as a starting point for creating your own manifest:

{
  "name": "lonely_yellow_beaver",
  "description": "Generated using bricks tf-rescue",
  "version": "1.0.0",
  "state": "managed",
  "props": {
    "bucket_name": {
      "description": "Fallback name for the bucket",
      "type": "string"
    }
  },
  "packages": [
    {
      "name": "aws_sqs_queue",
      "version": "1.0.1",
      "props": {}
    },
    {
      "name": "aws_simple_s3",
      "version": "0.1.1",
      "props": {
        "bucket_name": "Data.aws_sqs_queue.arn ?? Props.bucket_name"
      }
    }
  ]
}

Blueprint Vs. Artifact

The native block refers to IaC files archived together with the bricks.json file. It indicates to the orchestrator that besides building relationships, there are files that have to be executed.

A common practice is to create a set of native blueprints and wrap them with a non-native blueprint to orchestrate them all.

On runtime, each native blueprint is planned and applied separately, maintaining a small blast radius and speeding up the runtime.

Reference

Keys
Description
Mandatory

name

Blueprint name. It can't contain spaces, special characters, and dashes.

description

Free text explanation of the blueprint.

version

Blueprint version. Must follow Go's module version numberingarrow-up-right.

manifest_version

bricks.json schema version. Set to 1.

managed

Indicate whether Bluebricks manages the state of the blueprint.

repository

An object that describes the codebase location. Used for development.

repository.type

Repository vendor, currently, constant as git.

repository.url

Codebase URL to be used as reference.

props

Blueprint external API definition. Defines what properties are open for manipulation.

props.{{name}}

Property name, must be mapped to a IaC variable.

props.{{name}}.type

Type of property. Supported types: string, number, all

props.{{name}}.default

Default value of property. Overwritten by user-input.

props.{{name}}.description

Free text explanation of the property.

outs

Defines what outputs the package generates at the end of the execution.

outs.{{name}}

output name

outs.{{name}}.type

Type of output. Supported types: string, number, all

outs.{{name}}.value

Value of output.

outs.{{name}}.description

Free text explanation of the output.

packages

Nested Packages (Blueprints or Artifacts). Mandatory for Blueprints

packages.[].name

Blueprint name. Added automatically using bp add command.

packages.[].version

Blueprint version. Added automatically using bp add command.

packages.[].props

The blueprint properties. Defines the Semantic Trigger™ between sibling blueprints and default values to the nested blueprints.

packages.[].path

A URL pointed to the nested blueprint. Used by bp add-repo command.

native

IaC statement node. See Blueprint Vs. Artifact section. Mandatory for Artifacts.

native.type

Type of Infrastructure as Code, enum-based value - use bp create command.

native.path

Relative path to the IaC files.

Last updated

Was this helpful?