Blueprints (bprint)
Blueprint (bprint) command enables inclusive management of Atomic Infrastructure™ blueprints and artifacts. See Quick Start for a step-by-step guide.
Usage
bricks bp [flags]
bricks bp [command]Aliases
bprint, blueprint, bpAvailable Commands
add
Adding a registry-saved blueprint to the blueprint available in the working directory.
Help information for blueprint add
Usage:
bricks bprint add [package] [flags]
Flags:
--props string A pointer to a JSON file that include the properties to associate with the package.
--props-file string A JSON string of properties to associate with the package. This way a IaC turning opinionated.
--version string Package version.
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLIExample
~> bricks bprint add s3-bucket-configuration --props='{"bucket_name": "morty-pictures"}'
✓ s3-bucket-configuration added successfully.add-repo
Adding remote git repository URL to the blueprint available in the working directory.
Help information for blueprint add-repo
Usage:
bricks bprint add-repo [url] [flags]
Flags:
--props string A pointer to a JSON file that include the properties to customize the package
--props-file string A JSON string of properties to customize the package
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionUse URL-based blueprint for development and testing. Avoid using them in production because Bluebricks can't ensure runtime immutability.
Example
~> bricks bprint add-repo https://github.com/bluebricks-dev/artifacts/tree/main/terraform-aws-vpc
WARNING: URL-based blueprint added. Bluebricks can't ensure runtime immutability.
Consider wrapping the URL in a separate blueprint.
✓ Repository added successfully.bump
Update the version saved in the working folder bricks.json file.
Bump blueprint version
Usage:
bricks bprint bump [flags]
Flags:
--major Bump major version.
--minor Bump minor version.
--patch Bump patch version.
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionbump command doesn't update the registry. The developer must publish the blueprint using bricks bp publish command.
Example
~> bricks bp bump --minor
Updated version: 1.2.2create
Create a new IaC module for an existing blueprint. Adding a Terraform scaffolding to an Atomic Infrastructure™ blueprint or an artifact.
Create new IaC module for an exiting blueprint
Usage:
bricks bprint create [flags]
bricks bprint create [command]
Available Commands:
tf Scaffolding a Terraform module and updating bricks.json accordingly.
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI version
Use "bricks bprint create [command] --help" for more information about a command.Example
~> bricks bprint create tf
✓ Terraform template added to /Users/georgeclinton/Desktop/test/src/terraform
- add your code to main.tf
- set all variables in variables.tfdescribe
Print the bricks.json registry version of a blueprint
Printout the published bricks.json of the provided blueprint and version
Usage:
bricks bprint describe [package] [flags]
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bp describe @acme/aws_vpc
{
"name": "@acme/aws_vpc",
"description": "AWS VPC Atomic Infrasturcture Artifact",
"version": "1.2.1",
"native": {
"type": "terraform",
"path": "./src/terraform"
},
"props": {
"cidr": {
"default": "10.0.0.0/16",
"type":
// ... disable
Mark the blueprint as disabled for use in the organization. Disabled blueprints can't be installed.
Help information for blueprint disable
Usage:
bricks bprint disable [package] [flags]
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bp disable @acme/aws_vpc
✓ @acme/aws_vpc disabled successfully.enable
Mark the blueprint as enabled for use in the organization.
Help information for blueprint enable
Usage:
bricks bprint enable [package] [flags]
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bp enable @acme/aws_vpc
✓ @acme/aws_vpc enabled successfully.fetch
Download the provided blueprint from the registry
Downloading the provided blueprint from Bluebricks registry
Usage:
bricks bprint fetch [package] [flags]
Flags:
--output string The destination to download the blueprints.
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bp fetch @acme/aws_vpc
Blueprint files saved to `/Users/marksmith/Desktop/Blueprints/acme_aws_vpc`.get
Get the output values or input properties of a blueprint
List the outs or props configuration for a blueprint and its first level of children
Usage:
bricks bprint get [flags]
bricks bprint get [command]
Available Commands:
outs List outs of the provided blueprint
props List props of the provided blueprint
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI version
Use "bricks bprint get [command] --help" for more information about a command.Example
~> bricks bp get outs @acme/aws_vpc
`@acme/aws_vpc`:
NAME VALUE TYPE DESCRIPTION
security_group_id string The ID of the security group created by default on VPC creation
vpc_cidr_block string The CIDR block of the VPC
vpc_id string The ID of the VPC
private_subnets string List of IDs of private subnets
public_subnets string List of IDs of public subnetsinit
Initialize an empty Atomic Infrastructure™ project locally by creating bricks.json file. Learn more about bricks.json here.
Help information for blueprint init
Usage:
bricks bprint init [flags]
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bprint init
This utility will walk you through creating a bricks.json file.
It only covers the most common items, and tries to guess sensible defaults.
See `bricks blueprint init --help` for documentation on these fields
and all other options.
Press ^C at any time to quit.
package name: [test] maggot-brain
version: [1.0.0] 1.9.2
description: Studio album by Funkadelic
author: google-oauth2|110270771151464173524
git repository: https://github.com/bluebricks-co/homebrew-bricks
licence: [ISC]
About to write to /Users/georgeclinton/Desktop/test/bricks.json:
{
"author": "google-oauth2|110270771151464173524",
"name": "maggot-brain",
"description": "Studio album by Funkadelic",
"licence": "ISC",
"version": "1.9.2",
"repository": {
"type": "git",
"url": "https://github.com/bluebricks-co/homebrew-bricks"
}
}
Is this OK? [yes]
Configuration saved successfully.prepare
Ensure blueprint's Terraform files suites Atomic Infrastructure™ concept.
Usage:
bricks bprint prepare [flags]
Flags:
-h, --help help for prepare
-o, --output string destination to output, working directory (.) is default
-s, --source string files source, working directory (.) is defaultExample
~> bricks-cli bprint prepare
Your current .tf files will be overwritten. Are you sure you want to continue? [Yn]
Refactored files saved to /Users/georgeclinton/Desktop/Funkadelic/src-filespublish
Upload blueprint files to Bluebricks' package registry and assign an immutable version for future installation. See Quick Start to learn more about the publishing workflow.
Help information for blueprint publish
Usage:
bricks bprint publish [flags]
Flags:
--private Define if the package should be available for other users than the user’s organization. (default true)
--src string Blueprint location.
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bp publish
✓ aws-maggot-brain published successfully.remove
Delete a link to another blueprint that was added using add command.
Help information for blueprint remove
Usage:
bricks bprint remove [package] [flags]
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bprint remove aws-maggot-brain
✓ aws-maggot-brain removed successfully.search
Conduct a remote search in the Bluebricks registry of the provided query.
Conduct a blueprint search
Provide a search query to find blueprints that match the query.
Usage:
bricks bprint search [flags]
Flags:
-q, --query string Search query
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
bricks bp search --query="*aws*"
VERSION NAME STATUS DOWNLOADS CREATED URL
1.5.5 @acme/aws_rds enabled 1 2024-10-15T08:18:27.932Z
1.0.5 @acme/aws_sqs enabled 1 2024-10-07T18:33:38.997Z
1.1.1 @acme/aws_single_ec2 enabled 1 2024-10-01T12:18:16.231Z
1.2.1 @acme/aws_vpc enabled 1 2024-09-27T20:39:25.851Z
0.1.0 aws_ec2 disabled 1 2024-09-16T08:17:37.160Z
0.1.0 aws_vpc disabled 1 2024-09-16T08:10:56.444Z https://github.com/bluebricks-dev/demo-blueprints
────────────────────────── ───────────────────────────────────────────────────
total 6The results are limited to 10 rows
Each row includes the following columns (from left to right):
Version
Name
Enable/Disable - indicate whether the Blueprint can be installed or not
Number of Downloads
Creation Date
Git Repository URL
update
Update nested blueprint in a bricks.json file.
Help information for blueprint update
Usage:
bricks bprint update [package] [flags]
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bprint update aws-maggot-brain
Version 0.1.1 is the latest. Proceed with update? [Yn] ~> bricks bprint update [email protected]
Version 0.1.1 is the latest. Proceed with update? [Yn] view
List all available versions of the provided blueprint or artifact.
List all versions of a blueprint
Usage:
bricks bprint view [package] [flags]
Examples:
bricks bp view <blueprint-name>
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
~> bricks bp view @acme/aws_vpc
VERSION DOWNLOADS CREATED
1.2.1 1 2024-10-01T12:17:13.643Z
1.1.0 2 2024-09-28T12:39:39.586Z
1.0.7 3 2024-09-27T20:39:25.851Z
─────────── ──────────────────────────
total 3Each row includes the following columns (from left to right):
Version
Number of Downloads
Creation Date
state-config
Create a backend.tf file for an Artifact pointing to a remote state for local development.
Create a backend.tf file for an Artifact pointing to a remote state for local development.
Usage:
bricks bp state-config <deployment-slug> [flags]
Examples:
bricks bp state-config <deployment-slug>
Global Flags:
--config string config file (default is $HOME/.bricks/config.yaml)
-h, --help Print Help message for Bricks CLI
-v, --version Print bricks CLI versionExample
Fetch remote state configuration for deployment with slug my-sqs-prod:
bricks bp state-config my-sqs-prodThe bricks bp state-config command retrieves the remote Terraform/OpenTofu state configuration for the specified deployment slug and performs the following actions:
Generates a
backend.tffile in the current directory containing the remote state configuration.Includes a
variablesmap creates a temporary Terraform/OpenTofu variables file (bbx-temp-terraform.auto.tfvars) with the properties from the last successful deployment
Enables seamless local development with the same configuration as the deployed environment.
Last updated
Was this helpful?

