Overview
OpenSearch is an open-source distributed search and analytics engine. This template deploys a production-ready OpenSearch cluster with automated node configuration, an optional Dashboards visualization UI, an optional demo log pipeline, and optional scheduled snapshot backups to AWS S3 or GCS.What Gets Created
- Stateful Workload — An OpenSearch cluster with a configurable number of replicas (must be odd). Installs S3 or GCS repository plugins at startup when backup is enabled.
- Volume Set — Persistent storage per replica with optional autoscaling.
- Secret — An opaque startup script secret that generates the OpenSearch node configuration and starts the process.
- Identity & Policy — An identity bound to the OpenSearch workload with
revealaccess to the startup script secret. When backup is enabled, the identity also grants cloud storage access to the cluster. - OpenSearch Dashboards Workload (optional) — A web-based visualization UI for logs and data. Enabled when
dashboard.enabled: true. Not exposed externally — access viacpln port-forward. - Demo Logs Workload (optional) — A Python log generator with a Fluent Bit sidecar that ships sample logs to OpenSearch, plus a one-time setup job that creates index templates and dashboard patterns. Creates an additional Fluent Bit config secret with its own identity and policy. Enabled when
demoLogs.enabled: true. - Backup Setup Workload (optional) — A one-time job that registers the snapshot repository and creates an automated snapshot policy via the OpenSearch API. Enabled when
backup.enabled: true.
This template does not create a GVC. You must deploy it into an existing GVC.
Prerequisites
Prerequisites are only required if you plan to enable automated backups (backup.enabled: true). Skip this section if backups are not needed.
AWS S3
-
Create an S3 bucket. Set
backup.aws.bucketandbackup.aws.regionin your values file. -
If you do not have a Control Plane Cloud Account set up, follow the Create a Cloud Account guide. Set
backup.aws.cloudAccountNameto the name of your Cloud Account. -
Create an IAM policy with the following JSON, replacing
YOUR_BUCKET_NAME:
- Set
backup.aws.policyNameto the name of the policy created in step 3.
GCS
-
Create a GCS bucket. Set
backup.gcp.bucketin your values file. -
If you do not have a Control Plane Cloud Account set up, follow the Create a Cloud Account guide. Set
backup.gcp.cloudAccountNameto the name of your Cloud Account. - Add the Storage Admin role to the GCP service account associated with the Cloud Account.
Installation
To install, follow the instructions for your preferred method:UI
Browse, install, and manage templates visually
CLI
Manage templates from your terminal
Terraform
Declare templates in your Terraform configurations
Pulumi
Declare templates in your Pulumi programs
Configuration
The defaultvalues.yaml for this template:
Cluster
replicas— Number of OpenSearch nodes. Must be an odd number (3, 5, 7) to ensure quorum.clusterName— Name used for internal cluster coordination.
Use a minimum of 3 replicas for high availability. For production workloads, plan resources based on log volume: 1 CPU / 4Gi handles 10–50 GB/day; scale to 2 CPU / 8Gi for 50–100 GB/day.
Resources
resources.minCpu/resources.minMemory— Minimum CPU and memory guaranteed per node.resources.maxCpu/resources.maxMemory— Maximum CPU and memory per node.
Storage
volumeset.capacity— Initial volume size per node in GiB (minimum 10).volumeset.autoscaling.enabled— Automatically expand each volume as it fills. When enabled:maxCapacity— Maximum volume size in GiB.minFreePercentage— Trigger a scale-up when free space drops below this percentage.scalingFactor— Multiply the current capacity by this factor when scaling up.
Internal Access
internal_access.type— Controls which workloads can connect to OpenSearch on port9200:
| Type | Description |
|---|---|
same-gvc | Allow access from all workloads in the same GVC |
same-org | Allow access from all workloads in the same organization |
workload-list | Allow access only from specific workloads listed in workloads |
External access to OpenSearch is blocked by default. The Dashboards UI is also not exposed externally — use
cpln port-forward to access it.OpenSearch Dashboards
dashboard.enabled— Whentrue, deploys an OpenSearch Dashboards workload for log visualization and search. Recommended for most deployments.dashboard.resources.cpu/dashboard.resources.memory— CPU and memory for the Dashboards workload.
http://localhost:5601 in your browser.
Demo Logs
demoLogs.enabled— Whentrue, deploys a sample log generator with a Fluent Bit sidecar that ships logs to OpenSearch, along with a setup job that creates the index template and dashboard pattern. Useful for testing the pipeline end-to-end.demoLogs.remove_setup_workload— Set totrueafter the setup job completes (~1–2 minutes) to remove the one-time setup workload and reduce resource usage. The log pipeline continues running.
Backup
Setbackup.enabled: true to enable automated OpenSearch snapshot backups.
The backup setup workload registers the snapshot repository and creates the snapshot policy via the OpenSearch API. Once it completes successfully, set backup.remove_setup_workload: true and run cpln helm upgrade to remove it — snapshots will continue on schedule.
backup.provider—awsorgcp.backup.schedule— Cron schedule for automated snapshots (UTC).backup.retention.maxAge— Delete snapshots older than this duration.backup.retention.maxCount— Maximum number of snapshots to retain.
backup.provider to aws or gcp and fill in the corresponding provider section.
Restoring a Snapshot
Restore snapshots from any workload that can reach the cluster on port9200.
Restore to an empty cluster: