Skip to content

panlm/thanos-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 

Repository files navigation

README

目录说明

  • prometheus: 包含针对 prometheus operator 的定制 Values
  • s3-config: 提供 Thanos 组件访问 S3 的相关配置信息,这些配置将会被创建成 kubernetes 的 secret
  • thanos-values: 包含针对 bitnami thanos chart 的定制 Values
  • thanos-yaml: 包含自建 Thanos 使用的相关 Yaml 定义文件。更多模板参考 link

setup variable for your POC environment

为了方便部署,配置模板中预置了变量,使用下面脚本创建实验用的目录,并且针对你的实验环境替换相应的变量。配合本实验环境使用的 Terraform 脚本参见(github)。

DATE=$(TZ=EAT-8 date +%m%d)
CLUSTER_NAME_1=ekscluster1
CLUSTER_NAME_2=ekscluster2
CLUSTER_NAME_3=ekscluster3
DOMAIN_NAME=thanos.eks${DATE}.aws.panlm.xyz
THANOS_BUCKET_NAME=thanos-store-${DATE}-$RANDOM
AWS_DEFAULT_REGION=us-east-2
export CLUSTER_NAME_1 CLUSTER_NAME_2 CLUSTER_NAME_3 DOMAIN_NAME THANOS_BUCKET_NAME AWS_DEFAULT_REGION

aws s3 cb s3://${THANOS_BUCKET_NAME}

mkdir POC
cd POC-template
find ./ -type d -name "[a-z]*" -exec mkdir ../POC/{} \;

find ./ -type f -name "*" |while read filename ; do
  cat $filename |envsubst '$CLUSTER_NAME_1 $CLUSTER_NAME_2 $CLUSTER_NAME_3 $DOMAIN_NAME $THANOS_BUCKET_NAME $AWS_DEFAULT_REGION' > ../POC/$filename
done

refer

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published