Skip to main content

diagrid clusters connect

Connect a Kubernetes cluster

Description

Register a cluster connection with Conductor and optionally returns the Kubernetes manifest file for deploying the Conductor agent.

diagrid clusters connect [flags]

Examples


# Create a non production cluster connection without installing Dapr
diagrid clusters connect --name my-cluster

# Create a production cluster connection without installing Dapr
diagrid clusters connect --name my-cluster --type prod

# Create a non production cluster connection without installing Dapr
diagrid clusters connect --name my-cluster --type nonprod

# Create a cluster connection installing Dapr version 1.8.4 using the dev profile
diagrid clusters connect --name my-cluster --install-dapr --version 1.8.4 --profile dev

# Create a cluster connection installing Dapr version 1.8.4 using the dev profile, enable automatic agent upgrades, enable automatic Dapr config sync and rollout all Dapr enabled apps
diagrid clusters connect --name my-cluster --install-dapr --version 1.8.4 --profile dev --auto-agent --auto-sync --rollout-all

# Create a cluster connection installing Dapr using the dev profile and apply the agent manifests to the current Kubernetes cluster
diagrid clusters connect --name my-cluster --install-dapr --version 1.8.4 --profile dev --auto-agent --auto-sync --rollout-all --manifests | kubectl apply -f -

# Create a cluster connection installing Dapr using a custom Helm values file
diagrid clusters connect --name my-cluster --install-dapr --version 1.8.4 -f my-helm-values.yaml --auto-agent --auto-sync --rollout-all

# Create a cluster connection using a non-interactive session
diagrid clusters connect --name my-cluster --install-dapr --version 1.8.4 --profile dev --api-key <your-api-key>

# Create a cluster connection setting custom resource requests and limits for all the Conductor agent containers
diagrid clusters connect -n my-cluster --reporter-resource-requests cpu=100m,memory=200Mi --reporter-resource-limits cpu=300m,memory=500Mi --metrics-resource-requests cpu=100m,memory=200Mi --metrics-resource-limits cpu=300m,memory=500Mi --logs-resource-requests cpu=100m,memory=200Mi --logs-resource-limits cpu=300m,memory=500Mi

# Create a cluster connection setting custom node selectors for the agent deployment and the logs collector daemonset
diagrid clusters connect -n my-cluster --agent-node-selector my-node-label=test,other=test2 --logs-node-selector my-node-label=test,other=test2

# Create a cluster connection setting custom tolerations for the agent deployment
diagrid clusters connect -n my-cluster --agent-tolerations key=type,operator=Equal,value=highmem,effect=NoSchedule --agent-tolerations key=autoscaled,operator=Equal,value=true,effect=NoSchedule

# Create a cluster connection setting custom tolerations for the logs collector daemonset
diagrid clusters connect -n my-cluster --logs-tolerations key=autoscaled,operator=Equal,value=true,effect=NoSchedule --logs-tolerations key=type,operator=Equal,value=highmem,effect=NoSchedule

# Create a cluster connection setting custom csv of http proxy, https proxy, no proxy and custom CA certificate path
diagrid clusters connect -n my-cluster --http-proxy http://my-http-proxy-1:8080 --https-proxy https://my-https-proxy:8080 --no-proxy localhost,.diagrid.io --custom-ca-path /path/to/custom-ca.pem

Options

      --additional-ca-certs-path string     Additional CA certificates PEM file path for the cluster. This file will be added to the system CA certs folder on the container.
--agent-node-affinity stringArray Kubernetes node affinity for the agent deployment (e.g. --agent-node-affinity type=required,key=kubernetes.io/os,operator=In,values=linux --agent-node-affinity type=preferred,key=zone,operator=In,values=us-west1-a,us-west1-b,weight=10)
--agent-node-selector string Kubernetes node selector for the agent deployment (e.g. --agent-node-selector my-node-label=test,other=test2 )
--agent-tolerations stringArray Kubernetes tolerations for the agent deployment (e.g. --agent-tolerations key=autoscaled,operator=Equal,value=true,effect=NoSchedule --agent-tolerations key=type,operator=Equal,value=highmem,effect=NoSchedule )
--agentNamespace string Set Custom agent namespace (default "diagrid-cloud")
--api-key string Diagrid Cloud API key
-a, --auto-agent Enable automatic agent upgrades
--auto-sync Enable automatic Dapr config sync
--debug Enable debug mode
-f, --helm-values-file string Custom Helm values.yaml filepath
-h, --help help for connect
--http-proxy string URL of your http proxy server for the cluster
--https-proxy string URL of your https proxy server for the cluster
-i, --install-dapr Install dapr
--kubernetes-distro string Kubernetes distribution of target cluster (eks, aks, gke, openshift, local, native) (default "native")
--kubernetes-version string Kubernetes version of target cluster (default "1.24.2")
-l, --labels string Kubernetes labels for the agent (e.g. -l env=test,other=test2 )
--logs-node-affinity stringArray Kubernetes node affinity for the logs collector daemonset (e.g. --logs-node-affinity type=required,key=kubernetes.io/os,operator=In,values=linux --logs-node-affinity type=preferred,key=zone,operator=In,values=us-west1-a,us-west1-b,weight=10 )
--logs-node-selector string Kubernetes node selector for the logs collector daemonset (e.g. --logs-node-selector my-node-label=test,other=test2 )
--logs-resource-limits string Kubernetes resource limits for the logs collector container (e.g. --logs-resource-limits cpu=300m,memory=500Mi )
--logs-resource-requests string Kubernetes resource requests for the logs collector container (e.g. --logs-resource-requests cpu=100m,memory=200Mi )
--logs-tolerations stringArray Kubernetes tolerations for the logs collector daemonset (e.g. --logs-tolerations key=autoscaled,operator=Equal,value=true,effect=NoSchedule --logs-tolerations key=type,operator=Equal,value=highmem,effect=NoSchedule )
--managed-certificates Enabled managed certificates
-m, --manifests Wait for the Conductor agent manifests to be available and return them
--metrics-resource-limits string Kubernetes resource limits for the metrics collector container (e.g. --metrics-resource-limits cpu=300m,memory=500Mi )
--metrics-resource-requests string Kubernetes resource requests for the metrics collector container (e.g. --metrics-resource-requests cpu=100m,memory=200Mi )
-n, --name string Cluster name
--namespace string Dapr namespace (default "dapr-system")
--no-proxy string Comma separated list of URL to not send through the proxy
-o, --output string Output format, supported [table, yaml, json] (default "table")
--platform string OS platform of target cluster (default "linux/amd64")
-p, --profile string Profile for installing Dapr (dev, prod)
--reporter-resource-limits string Kubernetes resource limits for the reporter container (e.g. --reporter-resource-limits cpu=300m,memory=500Mi )
--reporter-resource-requests string Kubernetes resource requests for the reporter container (e.g. --reporter-resource-requests cpu=100m,memory=200Mi )
-r, --rollout-all Enable the rollout of all Dapr applications after a Dapr config update
--type string Cluster type (prod, nonprod) (default "nonprod")
-v, --version string Dapr version to be installed (default "1.9.3")

SEE ALSO