All Products
Search
Document Center

Simple Log Service:Use CRs to manage Logtail configurations

Last Updated:Jun 04, 2026

Simple Log Service defines two Kubernetes CRDs—AliyunPipelineConfig and AliyunLogConfig—that let you manage Logtail configurations as CustomResources (CRs).

Overview

A CRD extends the Kubernetes API to define custom resource types. Each CR is an instance of a CRD. Extend the Kubernetes API with CustomResourceDefinitions.

To manage Logtail configurations with CRs, connect to your Kubernetes cluster, authenticate, and submit a YAML file to the kube-apiserver to create a CR.

Warning

If you create a Logtail configuration through a CR, always update it through the CR. Changes made in the SLS console do not sync back to the CR.

Implementation of CR-based Logtail configuration management

image
  1. SLS creates a Deployment that installs alibaba-log-controller, which monitors changes to the AliyunLogConfig CRD.

  2. When you create, update, or delete an AliyunLogConfig CR through kubectl or other tools, alibaba-log-controller detects the change and sends the corresponding request to SLS—for example, updating the Logtail configuration.

CRDs

SLS provides two CRDs for managing Logtail configurations in Kubernetes: AliyunPipelineConfig and AliyunLogConfig. The following table compares their capabilities.

Important

AliyunPipelineConfig requires Logtail 0.5.1 or later.

CRD

AliyunPipelineConfig (recommended)

AliyunLogConfig

ApiGroup

telemetry.alibabacloud.com/v1alpha1

log.alibabacloud.com/v1alpha1

CRD resource name

ClusterAliyunPipelineConfig

AliyunLogConfig

Scope

Cluster

Namespace

Logtail configuration format

Equivalent to LogtailPipelineConfig

Equivalent to LogtailConfig

Cross-region capability

Supported

Supported

Cross-account capability

Supported

Supported

Webhook-related parameter verification

Supported

Not supported

Configuration conflict detection

Supported

Supported (Logtail 0.5+)

Configuration difficulty

Relatively low

Relatively high

Observability configuration

The Status field includes error details, update time, the previously applied Logtail configuration, and when it was applied.

The Status field contains the error code and error message.