
本Docker镜像提供了与AWS OpenSearch 1.3.0版本兼容的Elastic Curator工具。Elastic Curator是一款用于管理Elasticsearch/OpenSearch索引生命周期的工具,可实现索引的创建、删除、优化、快照等操作,帮助用户自动化索引管理流程,提升集群性能和资源利用率。
1. 拉取镜像
bashdocker pull [镜像仓库地址]/elastic-curator-aws-opensearch:latest
2. 运行容器
基本命令格式:
bashdocker run -v /path/to/config:/config [镜像仓库地址]/elastic-curator-aws-opensearch:latest curator [命令] /config/action.yml
需准备两个核心配置文件:
yamlclient: hosts: - https://your-opensearch-endpoint.amazonaws.com:443 aws_sign_request: True # 启用AWS签名请求 region: us-east-1 # AWS区域 ssl: verify_certs: True logging: loglevel: INFO
yamlactions: 1: action: delete_indices description: "删除30天前的日志索引" options: ignore_empty_list: True timeout_override: continue_if_exception: False disable_action: False filters: - filtertype: pattern kind: prefix value: log- - filtertype: age source: creation_date direction: older unit: days unit_count: 30
bashdocker run -v /local/path/to/config:/config \ -e AWS_ACCESS_KEY_ID=your-access-key \ -e AWS_SECRET_ACCESS_KEY=your-secret-key \ [镜像仓库地址]/elastic-curator-aws-opensearch:latest \ curator /config/action.yml --config /config/config.yml
| 环境变量 | 说明 | 必要性 |
|---|---|---|
| AWS_ACCESS_KEY_ID | AWS访问密钥ID | 当使用IAM认证时必填 |
| AWS_SECRET_ACCESS_KEY | AWS密钥 | 当使用IAM认证时必填 |
| AWS_REGION | AWS区域 | 当未在config.yml中指定时必填 |
| OPENSEARCH_HOST | OpenSearch服务端点 | 当未在config.yml中指定时必填 |
可结合crontab实现周期性执行:
bash# 每天凌晨2点执行索引清理 0 2 * * * docker run -v /path/to/config:/config -e AWS_ACCESS_KEY_ID=xxx -e AWS_SECRET_ACCESS_KEY=xxx [镜像仓库地址]/elastic-curator-aws-opensearch:latest curator /config/action.yml --config /config/config.yml >> /var/log/curator.log 2>&1





探索更多轩辕镜像的使用方法,找到最适合您系统的配置方式
通过 Docker 登录认证访问私有仓库
无需登录使用专属域名
Kubernetes 集群配置 Containerd
K3s 轻量级 Kubernetes 镜像加速
VS Code Dev Containers 配置
Podman 容器引擎配置
HPC 科学计算容器配置
ghcr、Quay、nvcr 等镜像仓库
Harbor Proxy Repository 对接专属域名
Portainer Registries 加速拉取
Nexus3 Docker Proxy 内网缓存
需要其他帮助?请查看我们的 常见问题Docker 镜像访问常见问题解答 或 提交工单
manifest unknown
no matching manifest(架构)
invalid tar header(解压)
TLS 证书失败
DNS 超时
410 Gone 排查
402 与流量用尽
401 认证失败
429 限流
D-Bus 凭证提示
413 与超大单层
来自真实用户的反馈,见证轩辕镜像的优质服务