Skip to content
DocsTry Aspire
DocsTry

K3sClusterResource Properties

ClassProperties5 members
Represents a k3s Kubernetes cluster running as a privileged container resource. Injects the cluster's kubeconfig into a dependent resource.
  • Host processes receive KUBECONFIG=<host-path>/local/kubeconfig.yaml.
  • Containers receive KUBECONFIG=/tmp/k3s-kubeconfig.yaml and a file-level bind-mount of the container-network kubeconfig variant. Both are applied by the BeforeStartEvent subscriber registered in AddK3sCluster.
ApiEndpointSection titled ApiEndpointEndpointReference
Gets the endpoint reference for the k3s API server (port 6443).
public EndpointReference ApiEndpoint { get; }
ConnectionStringEnvironmentVariableSection titled ConnectionStringEnvironmentVariablenullablestring?
Overrides the default ConnectionStrings__ prefix so Aspire injects KUBECONFIG.
public string? ConnectionStringEnvironmentVariable { get; }
ConnectionStringExpressionSection titled ConnectionStringExpressionReferenceExpression
Manifest expression for the local kubeconfig path.
public ReferenceExpression ConnectionStringExpression { get; }
HelmReleasesSection titled HelmReleasesIReadOnlyDictionary<string, string>
A dictionary of registered Helm releases keyed by resource name.
public IReadOnlyDictionary<string, string> HelmReleases { get; }
ManifestsSection titled ManifestsIReadOnlyList<string>
Names of registered K8sManifestResource children.
public IReadOnlyList<string> Manifests { get; }