How Blueprint Installation Works

The Bluebricks installation uses a published, immutable version to deploy its configuration, following any defined dependencies, onto the targeted environment.

In the following document, we’ll review how the installation process flows from the initiator—such as the CLI or API—through the orchestrator and ultimately to the cloud account.

Installation Sequence

The sequence diagram below illustrates the installation flow, detailing each step to help you understand how the process operates from initiation to deployment.

Installations on Bluebricks are divided into two phases, regardless of which Infrastructure as Code language is used underneath: plan and apply.

Practitioners can define if the process should wait for their approval or automatically proceed to the deployment and skip the planning stage.

Plan Stage

When a client initiates an installation flow using the install command, Bluebricks creates a task on the backend to manage the workflow.

Immediately afterward, the Bluebricks Orchestrator pulls pending tasks from the backend and begins processing the bricks.json of the top-level blueprint.

The Orchestrator constructs a directed acyclic graph (DAG) based on the provided properties, preparing a dependency tree to establish the planning sequence. Planning commences once the DAG is complete, iterating only over the blueprints included in the sequence.

During planning, the Orchestrator continuously updates the backend with its progress. Once planning for all blueprints is complete, the backend updates the task status and notifies the client.

At this point, the client can approve or reject the plan. When the client approves the plan, the task progresses to the next stage: applying changes.

Apply Stage

When the user approves a plan, their client application sends an approval request to the backend, which updates the task stage to "installation pending."

Much like in the planning stage, the Orchestrator quickly retrieves the task and begins executing the planned files.

During each iteration, the Orchestrator collects the output of each package and passes it to the next package in the sequence.

The implementation sequence follows the same order as the planned sequence.

Once the installation is complete, the Orchestrator updates the backend and uploads an obfuscated shadow state to the backend.

Installation Sequence

Here is the full sequence of actions:

  1. Initiation: The client triggers the installation flow using the install command.

  2. Task Creation: Bluebricks creates a task on the backend to manage the workflow.

  3. Task Processing: The Orchestrator retrieves pending tasks from the backend and processes the bricks.json of the top-level blueprint.

  4. DAG Construction: The Orchestrator builds a directed acyclic graph (DAG) based on provided properties, establishing a dependency tree for planning.

  5. Planning: The Orchestrator iterates over the blueprints in the sequence, updating the backend with progress. Once planning completes, the backend updates the task status and informs the client.

  6. Client Approval: The client reviews the plan and can approve or reject it.

  7. Approval Request: If approved, the client sends an approval request to the backend, updating the task’s stage to “installation pending.”

  8. Execution: The Orchestrator retrieves the task and starts executing the planned files.

  9. Output Collection: During each iteration, the Orchestrator collects the output from each package and forwards it to the next package in the sequence, following the planned sequence.

  10. Completion: Upon completion of the installation, the Orchestrator updates the backend and uploads an obfuscated shadow state for tracking purposes.

This sequence ensures a streamlined and structured installation flow from initiation to completion.

Last updated

Was this helpful?