This page is incomplete

This page assumes you’ve worked through the tutorials and is meant to distill the concept taught in those. If you haven’t already gone through them, please start there.

This outlines a sample workflow using Sugarkube to spin up and tear down Kubernetes clusters.

Set up

  1. Define your stack
  2. Create some manifests
  3. Create some kapps or use ours

Dev workflow

  1. Create a workspace for your target cluster with workspace create.
  2. If you don’t use the cluster_update action to create a cluster, explicitly create a cluster by running cluster create. Don’t do this if one of your kapps/manifests calls that action though.
  3. Run kapps install to install your kapps (and create your cluster if they call the cluster_update action)
  4. Do your work - by editing/creating new kapps as necessary, and running kapps install -i <manifest:kapp-id> to reinstall just the kapp you’re working on.
  5. Tag your new kapps and update your configs to deploy the new kapp to a target cluster.
  6. Tear down your dev cluster with kapps delete.
  7. If no kapp declares the cluster_delete action, manually run cluster delete.

Other useful commands while you’re developing a kapp are:

  • cluster vars - see all the interpolated, merged variables for your target cluster
  • kapp vars - see the output of cluster vars plus the values of variables that will be supplied to your kapp and the values of any available outputs
  • kapp template - render templates declared in your kapp
  • kapp clean - run make clean across all your kapps to reset their state