Skip to content

Local Deployment using Infrastructure as Code

This guide describes how to deploy a two-party Carbyne Stack Virtual Cloud onto local kind cluster using CDKTF.

Setup

  1. Clone the carbynestack/carbynestack repository

    git clone git@github.com:carbynestack/carbynestack.git
    
  2. Change into the carbynestack directory

    cd carbynestack
    
  3. Checkout the tag sdk-v0.5.0

    git checkout tags/sdk-v0.5.0
    
  4. Change directory to the deployments folder

    cd deployments
    
  5. Install npm dependencies:

    npm install
    
  6. Generate CDKTF provider bindings and import modules (located in the .gen folder):

    cdktf get
    

Deploy

In the ./deployments folder:

  1. Deploy the stack using

    cdktf deploy local-kind
    

Destroy and Clean Up

If you no longer need the stack or want to tear it down to apply changes to the infrastructure as code, run the following command:

cdktf destroy

Alternatively, you can use:

kind delete clusters cs-1 cs-2

And delete the CDKTF state files (like terraform.local-kind.tfstate) manually.

Back to top