Skip to main content

Quickstart

This guide is the quickest way to get started and experience Conductor and takes approximately 10 minutes. You will create a local Kubernetes cluster, install Dapr and Conductor, deploy a sample application, and troubleshoot a simulated infrastructure failure.

Prerequisites

Review the complete list of Conductor requirements for various configurations. This quickstart requires the following:

1. Create a Kubernetes cluster

Conductor is compatible with Minikube, Kind, and most other Kubernetes distributions. Follow the respective installation guide suitable for your operating system and hardware architecture. This guide demonstrates the installation and configuration for Kind and Minikube on MacOS.

Refer to Minikube for installation instructions across various environments. To install Minikube on MacOS using Homebrew, execute:

brew install minikube

After installation, start a local Kubernetes cluster using Minikube. The default configuration allocates 2 CPUs and 2GB of memory, which is sufficient to run everything in this quickstart.

minikube start

Verify that Kubernetes is operational with:

minikube status
Metric Server Dependency

Conductor depends on metrics server, which is pre-installed on some managed Kubernetes distributions. In this quickstart, the metrics server will be installed using Conductor.

2. Create a Cluster Connection

If you do not have a Conductor account, first sign up for Conductor Free. Log in to the Conductor console to create your first cluster connection.

create-cluster-connection

  1. Name your cluster connection and select Local (MiniKube, Kind, Docker Desktop) as the Kubernetes distribution.

  2. Choose Install prerequisites to install the metrics server.

  3. Choose Install Dapr to install the latest version of Dapr control plane with recommended settings for local development. Alternatively, you can install Dapr into Kubernetes using Dapr CLI as part of the sample application dependencies installation later.

  4. Press Create to generate the Kubernetes manifests required for installing the Conductor agent and the selected Dapr configuration on the cluster.

3. Install Conductor Agent

The quickest way to install the Conductor Agent on your Kubernetes cluster is to copy and apply the generated manifest:

dapr

Copy the generated command and execute it locally with kubectl:

kubectl apply -f "YOUR_UNIQUE_CLUSTER_CONNECTION_TOKEN"

This installs the Conductor agent and links it to your Conductor cluster connection. The agent status in the Conductor console will switch from Offline to Online, and the Dapr control plane will display Healthy.

4. Run a Sample Dapr Application

With Conductor connected to Kubernetes, you're ready to run a Daprized application. We will deploy a straightforward distributed application from the Hello Kubernetes tutorial by the Dapr project. This application includes a Python App that generates messages and a Node App that saves these messages into a Redis state store. To streamline the deployment process, the conductor-quickstart repository will be used. This repo contains the necessary deployment and configuration files to install the Dapr applications.

Install Dapr and Redis

We will explore two methods to install Dapr and Redis on Kubernetes, using either Conductor and Helm, or Dapr CLI alone.

If you enabled Dapr installation while creating a Conductor cluster connection, the Dapr control plane should already be installed on Kubernetes. To deploy a Redis instance for development purposes, use the following Helm commands:

helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update
helm install redis bitnami/redis --set cluster.enabled=false --set replica.replicaCount=0 --set fullnameOverride=dapr-dev-redis

This command installs a single-container Redis cluster named dapr-dev-redis to align with the component and secret references in the sample application.

Deploy the Sample Application

With Dapr and Redis installed, you can now deploy the sample application. You can directly apply it onto the cluster from GitHub or clone the application repository and apply it locally.

Apply Kubernetes resources directly from the remote GitHub repository.

kubectl apply -f https://raw.githubusercontent.com/diagrid-labs/conductor-quickstart/main/deploy.yaml

This deployment creates pythonapp and nodeapp Deployments, along with a Service for nodeapp, and configures a Dapr statestore component as well as a resiliency policy. To monitor the initialization of the applications, navigate to the Applications tab in the Conductor console after selecting the appropriate cluster connection. Verify that the components are initialized successfully using the Initialization Status and check the resiliency policy remains inactive on the Resiliency tab.

dapr

The advisor panel displays potential improvements for your application. For a real-time view of the application's network topology, click on Apps Graph on the Applications page.

Troubleshoot a Failure

To simulate an infrastructure failure, scale down the Redis instances to zero.

kubectl scale statefulset dapr-dev-redis-master --replicas=0

In Conductor, observe the failure through various indicators:

  • The Component List will display the statestore component's Initialization Status as Error after scaling down.
  • The nodeapp application's component metrics graphs will show an increase in error rates.
  • The resiliency policy will activate and the retry rates will start increasing.
  • After a few minutes, there will be issues detected based on App Component Error Rate and HTTP Error Rate metrics.
  • The Apps Graph will highlight the erroneous component and its impact on the dependent applications.

dapr

To restore the application, scale the Redis instance back up to one.

kubectl scale statefulset dapr-dev-redis-master --replicas=1

Next steps

You are now equipped to use Conductor for automating Dapr management and improving insights into your Dapr Kubernetes workloads. For further exploration of Conductor features and to visualize additional failure scenarios, consider installing the Pizza Store System.