feat: add linter
This commit is contained in:
3
.gitignore
vendored
3
.gitignore
vendored
@@ -1,3 +1,6 @@
|
|||||||
|
# Node.js
|
||||||
|
node_modules/
|
||||||
|
|
||||||
# Ignore Helm chart default values files
|
# Ignore Helm chart default values files
|
||||||
*-values.yaml
|
*-values.yaml
|
||||||
values-*.yaml
|
values-*.yaml
|
||||||
|
|||||||
5
.vscode/extensions.json
vendored
Normal file
5
.vscode/extensions.json
vendored
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
"recommendations": [
|
||||||
|
"dbaeumer.vscode-eslint"
|
||||||
|
]
|
||||||
|
}
|
||||||
67
.vscode/settings.json
vendored
67
.vscode/settings.json
vendored
@@ -1,6 +1,10 @@
|
|||||||
{
|
{
|
||||||
|
// Disable Prettier, use ESLint for formatting instead
|
||||||
"prettier.enable": false,
|
"prettier.enable": false,
|
||||||
|
// Disable default formatOnSave, use ESLint fixOnSave
|
||||||
"editor.formatOnSave": false,
|
"editor.formatOnSave": false,
|
||||||
|
|
||||||
|
// Markdown settings
|
||||||
"[markdown]": {
|
"[markdown]": {
|
||||||
"editor.wordWrap": "on",
|
"editor.wordWrap": "on",
|
||||||
"editor.formatOnSave": true,
|
"editor.formatOnSave": true,
|
||||||
@@ -13,12 +17,61 @@
|
|||||||
"strings": "off"
|
"strings": "off"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// YAML settings: auto-fix ESLint issues on save
|
||||||
"[yaml]": {
|
"[yaml]": {
|
||||||
"editor.formatOnSave": true
|
"editor.formatOnSave": false,
|
||||||
},
|
"editor.codeActionsOnSave": {
|
||||||
"[dockercompose]": {
|
"source.fixAll.eslint": "explicit"
|
||||||
"editor.formatOnSave": true
|
}
|
||||||
},
|
},
|
||||||
"files.eol": "\n",
|
|
||||||
"cSpell.enabled": false
|
// Docker Compose settings
|
||||||
|
"[dockercompose]": {
|
||||||
|
"editor.formatOnSave": false,
|
||||||
|
"editor.codeActionsOnSave": {
|
||||||
|
"source.fixAll.eslint": "explicit"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
// File EOL configuration
|
||||||
|
"files.eol": "\n",
|
||||||
|
|
||||||
|
// Disable spell checking
|
||||||
|
"cSpell.enabled": false,
|
||||||
|
|
||||||
|
// ESLint settings: auto-fix on save
|
||||||
|
"editor.codeActionsOnSave": {
|
||||||
|
"source.fixAll.eslint": "explicit",
|
||||||
|
"source.organizeImports": "never"
|
||||||
|
},
|
||||||
|
|
||||||
|
// Silent stylistic rules in IDE but still auto-fix them
|
||||||
|
"eslint.rules.customizations": [
|
||||||
|
{ "rule": "style/*", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "format/*", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "*-indent", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "*-spacing", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "*-spaces", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "*-order", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "*-dangle", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "*-newline", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "*quotes", "severity": "off", "fixable": true },
|
||||||
|
{ "rule": "*semi", "severity": "off", "fixable": true }
|
||||||
|
],
|
||||||
|
|
||||||
|
// Enable ESLint for supported languages
|
||||||
|
"eslint.validate": [
|
||||||
|
"javascript",
|
||||||
|
"javascriptreact",
|
||||||
|
"typescript",
|
||||||
|
"typescriptreact",
|
||||||
|
"vue",
|
||||||
|
"html",
|
||||||
|
"markdown",
|
||||||
|
"json",
|
||||||
|
"jsonc",
|
||||||
|
"yaml",
|
||||||
|
"toml"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,15 +14,19 @@ The following services are currently supported:
|
|||||||
- Elasticsearch
|
- Elasticsearch
|
||||||
- etcd
|
- etcd
|
||||||
- Kafka
|
- Kafka
|
||||||
|
- Keycloak
|
||||||
- Kibana
|
- Kibana
|
||||||
- Langfuse
|
- Langfuse
|
||||||
|
- MariaDB
|
||||||
- Milvus
|
- Milvus
|
||||||
- MinIO
|
- MinIO
|
||||||
- MongoDB
|
- MongoDB
|
||||||
|
- Nginx
|
||||||
- OpenTelemetry Collector
|
- OpenTelemetry Collector
|
||||||
- Phoenix
|
- Phoenix
|
||||||
- PostgreSQL
|
- PostgreSQL
|
||||||
- RabbitMQ
|
- RabbitMQ
|
||||||
|
- RabbitMQ Cluster Operator
|
||||||
- Redis
|
- Redis
|
||||||
- Valkey
|
- Valkey
|
||||||
- ZooKeeper
|
- ZooKeeper
|
||||||
|
|||||||
35
eslint.config.mjs
Normal file
35
eslint.config.mjs
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
import antfu from '@antfu/eslint-config'
|
||||||
|
|
||||||
|
export default antfu({
|
||||||
|
// Enable YAML support
|
||||||
|
yaml: {
|
||||||
|
overrides: {
|
||||||
|
// For Helm values files, allow flexible string styles
|
||||||
|
'yaml/quotes': ['error', { prefer: 'single', avoidEscape: true }],
|
||||||
|
// 'yaml/plain-scalar': 'off',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
// Disable other language support we don't need
|
||||||
|
typescript: false,
|
||||||
|
vue: false,
|
||||||
|
react: false,
|
||||||
|
svelte: false,
|
||||||
|
astro: false,
|
||||||
|
// Enable stylistic formatting
|
||||||
|
stylistic: {
|
||||||
|
indent: 2,
|
||||||
|
quotes: 'single',
|
||||||
|
semi: false,
|
||||||
|
},
|
||||||
|
// Files to ignore
|
||||||
|
ignores: [
|
||||||
|
'**/node_modules/**',
|
||||||
|
'**/.git/**',
|
||||||
|
],
|
||||||
|
}, {
|
||||||
|
// Disable sort keys rule for JSON files
|
||||||
|
files: ['**/package.json'],
|
||||||
|
rules: {
|
||||||
|
'jsonc/sort-keys': 'off',
|
||||||
|
},
|
||||||
|
})
|
||||||
19
package.json
Normal file
19
package.json
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
{
|
||||||
|
"name": "helm-anything",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"description": "Helm command templates for quick service deployment",
|
||||||
|
"main": "index.js",
|
||||||
|
"scripts": {
|
||||||
|
"lint": "eslint .",
|
||||||
|
"lint:fix": "eslint . --fix",
|
||||||
|
"test": "echo \"Error: no test specified\" && exit 1"
|
||||||
|
},
|
||||||
|
"keywords": ["helm", "kubernetes", "deployment"],
|
||||||
|
"author": "",
|
||||||
|
"license": "ISC",
|
||||||
|
"packageManager": "pnpm@10.25.0",
|
||||||
|
"devDependencies": {
|
||||||
|
"@antfu/eslint-config": "^7.4.3",
|
||||||
|
"eslint": "^10.0.0"
|
||||||
|
}
|
||||||
|
}
|
||||||
2684
pnpm-lock.yaml
generated
Normal file
2684
pnpm-lock.yaml
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -3,7 +3,7 @@ clickhouse:
|
|||||||
shardsCount: 1
|
shardsCount: 1
|
||||||
antiAffinity: true
|
antiAffinity: true
|
||||||
defaultUser:
|
defaultUser:
|
||||||
password: "clickhouse-password" # Change me!
|
password: clickhouse-password # Change me!
|
||||||
allowExternalAccess: true
|
allowExternalAccess: true
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|||||||
@@ -2,18 +2,18 @@ replicas: 3
|
|||||||
minimumMasterNodes: 2
|
minimumMasterNodes: 2
|
||||||
|
|
||||||
volumeClaimTemplate:
|
volumeClaimTemplate:
|
||||||
accessModes: ["ReadWriteOnce"]
|
accessModes: [ReadWriteOnce]
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
storage: 30Gi
|
storage: 30Gi
|
||||||
|
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
cpu: "500m"
|
cpu: 500m
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
limits:
|
limits:
|
||||||
cpu: "1000m"
|
cpu: 1000m
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
|
|
||||||
esConfig:
|
esConfig:
|
||||||
elasticsearch.yml: |
|
elasticsearch.yml: |
|
||||||
@@ -25,14 +25,14 @@ esConfig:
|
|||||||
http.cors.allow-origin: "*"
|
http.cors.allow-origin: "*"
|
||||||
http.cors.allow-headers: Authorization,X-Requested-With,Content-Type,Content-Length
|
http.cors.allow-headers: Authorization,X-Requested-With,Content-Type,Content-Length
|
||||||
|
|
||||||
esJavaOpts: "-Xmx1g -Xms1g"
|
esJavaOpts: -Xmx1g -Xms1g
|
||||||
|
|
||||||
service:
|
service:
|
||||||
type: ClusterIP
|
type: ClusterIP
|
||||||
port: 9200
|
port: 9200
|
||||||
nodePort: ""
|
nodePort: ''
|
||||||
|
|
||||||
xpack:
|
xpack:
|
||||||
enabled: false
|
enabled: false
|
||||||
|
|
||||||
clusterHealthCheckParams: "wait_for_status=yellow&timeout=1s"
|
clusterHealthCheckParams: 'wait_for_status=yellow&timeout=1s'
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ spec:
|
|||||||
transaction.state.log.min.isr: 2
|
transaction.state.log.min.isr: 2
|
||||||
default.replication.factor: 3
|
default.replication.factor: 3
|
||||||
min.insync.replicas: 2
|
min.insync.replicas: 2
|
||||||
inter.broker.protocol.version: "3.6"
|
inter.broker.protocol.version: '3.6'
|
||||||
storage:
|
storage:
|
||||||
type: jbod
|
type: jbod
|
||||||
volumes:
|
volumes:
|
||||||
@@ -32,10 +32,10 @@ spec:
|
|||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
memory: 2Gi
|
memory: 2Gi
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
limits:
|
limits:
|
||||||
memory: 2Gi
|
memory: 2Gi
|
||||||
cpu: "2"
|
cpu: '2'
|
||||||
zookeeper:
|
zookeeper:
|
||||||
replicas: 3
|
replicas: 3
|
||||||
storage:
|
storage:
|
||||||
@@ -45,24 +45,24 @@ spec:
|
|||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
memory: 1Gi
|
memory: 1Gi
|
||||||
cpu: "0.5"
|
cpu: '0.5'
|
||||||
limits:
|
limits:
|
||||||
memory: 1Gi
|
memory: 1Gi
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
entityOperator:
|
entityOperator:
|
||||||
topicOperator:
|
topicOperator:
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
memory: 512Mi
|
memory: 512Mi
|
||||||
cpu: "0.2"
|
cpu: '0.2'
|
||||||
limits:
|
limits:
|
||||||
memory: 512Mi
|
memory: 512Mi
|
||||||
cpu: "0.5"
|
cpu: '0.5'
|
||||||
userOperator:
|
userOperator:
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
memory: 512Mi
|
memory: 512Mi
|
||||||
cpu: "0.2"
|
cpu: '0.2'
|
||||||
limits:
|
limits:
|
||||||
memory: 512Mi
|
memory: 512Mi
|
||||||
cpu: "0.5"
|
cpu: '0.5'
|
||||||
|
|||||||
16
src/keycloak/Makefile
Normal file
16
src/keycloak/Makefile
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
HELM_RELEASE_NAME ?= keycloak
|
||||||
|
HELM_APPLICATION_NAME ?= keycloak
|
||||||
|
HELM_NAMESPACE ?= keycloak
|
||||||
|
HELM_DIR ?= ./helm
|
||||||
|
HELM_CHART_VERSION ?= 0.15.1
|
||||||
|
HELM_VALUES_FILE ?= ./values.yaml
|
||||||
|
HELM_OCI_REGISTRY ?= docker.io
|
||||||
|
HELM_OCI_NAMESPACE ?= cloudpirates
|
||||||
|
HELM_OCI_USERNAME ?=
|
||||||
|
HELM_OCI_PASSWORD ?=
|
||||||
|
HELM_REPO_NAME ?=
|
||||||
|
HELM_REPO_URL ?=
|
||||||
|
HELM_CHART_REPO ?= oci://$(HELM_OCI_REGISTRY)/$(HELM_OCI_NAMESPACE)/$(HELM_APPLICATION_NAME)
|
||||||
|
HELM_LANE ?=
|
||||||
|
|
||||||
|
include ../_template/base.mk
|
||||||
79
src/keycloak/README.md
Normal file
79
src/keycloak/README.md
Normal file
@@ -0,0 +1,79 @@
|
|||||||
|
# Keycloak
|
||||||
|
|
||||||
|
## Introduction
|
||||||
|
|
||||||
|
Keycloak is an open source identity and access management solution. It provides user federation, strong authentication, user management, fine-grained authorization, and more.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
To install Keycloak, run:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make install
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
After installation, verify the deployment:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl get pods -n keycloak
|
||||||
|
```
|
||||||
|
|
||||||
|
To access Keycloak, port-forward the service:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl port-forward svc/keycloak 8080:8080 -n keycloak
|
||||||
|
```
|
||||||
|
|
||||||
|
Then access the admin console at <http://localhost:8080/admin>
|
||||||
|
|
||||||
|
Default credentials:
|
||||||
|
|
||||||
|
- Username: `admin`
|
||||||
|
- Password: (see `values.yaml` keycloak.adminPassword)
|
||||||
|
|
||||||
|
## Configuration
|
||||||
|
|
||||||
|
You can customize Keycloak by editing `values.yaml`:
|
||||||
|
|
||||||
|
- `keycloak`: Core Keycloak settings (admin user, hostname, production mode)
|
||||||
|
- `database`: External database configuration (PostgreSQL, MySQL, MariaDB)
|
||||||
|
- `postgres`: Embedded PostgreSQL configuration
|
||||||
|
- `ingress`: Configure ingress for external access
|
||||||
|
- `tls`: Enable TLS/HTTPS support
|
||||||
|
|
||||||
|
## Production Mode
|
||||||
|
|
||||||
|
For production deployments, set:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
keycloak:
|
||||||
|
production: true
|
||||||
|
hostname: keycloak.yourdomain.com
|
||||||
|
hostnameStrict: true
|
||||||
|
```
|
||||||
|
|
||||||
|
## External Database
|
||||||
|
|
||||||
|
To use an external database instead of the embedded PostgreSQL:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
postgres:
|
||||||
|
enabled: false
|
||||||
|
|
||||||
|
database:
|
||||||
|
type: postgres
|
||||||
|
host: postgres.example.com
|
||||||
|
port: 5432
|
||||||
|
name: keycloak
|
||||||
|
username: keycloak
|
||||||
|
password: your-password
|
||||||
|
```
|
||||||
|
|
||||||
|
## Documentation
|
||||||
|
|
||||||
|
For more information, see:
|
||||||
|
|
||||||
|
- [Keycloak Official Website](https://www.keycloak.org)
|
||||||
|
- [Keycloak Documentation](https://www.keycloak.org/documentation)
|
||||||
79
src/keycloak/README.zh.md
Normal file
79
src/keycloak/README.zh.md
Normal file
@@ -0,0 +1,79 @@
|
|||||||
|
# Keycloak
|
||||||
|
|
||||||
|
## 简介
|
||||||
|
|
||||||
|
Keycloak 是一个开源的身份和访问管理解决方案。它提供用户联合、强身份认证、用户管理、细粒度授权等功能。
|
||||||
|
|
||||||
|
## 安装
|
||||||
|
|
||||||
|
要安装 Keycloak,请运行:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make install
|
||||||
|
```
|
||||||
|
|
||||||
|
## 使用
|
||||||
|
|
||||||
|
安装后,验证部署:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl get pods -n keycloak
|
||||||
|
```
|
||||||
|
|
||||||
|
要访问 Keycloak,请端口转发服务:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl port-forward svc/keycloak 8080:8080 -n keycloak
|
||||||
|
```
|
||||||
|
|
||||||
|
然后在 <http://localhost:8080/admin> 访问管理控制台
|
||||||
|
|
||||||
|
默认凭据:
|
||||||
|
|
||||||
|
- 用户名:`admin`
|
||||||
|
- 密码:(参见 `values.yaml` 中的 keycloak.adminPassword)
|
||||||
|
|
||||||
|
## 配置
|
||||||
|
|
||||||
|
您可以通过编辑 `values.yaml` 来自定义 Keycloak:
|
||||||
|
|
||||||
|
- `keycloak`: 核心 Keycloak 设置(管理员用户、主机名、生产模式)
|
||||||
|
- `database`: 外部数据库配置(PostgreSQL、MySQL、MariaDB)
|
||||||
|
- `postgres`: 嵌入式 PostgreSQL 配置
|
||||||
|
- `ingress`: 配置 ingress 以进行外部访问
|
||||||
|
- `tls`: 启用 TLS/HTTPS 支持
|
||||||
|
|
||||||
|
## 生产模式
|
||||||
|
|
||||||
|
对于生产部署,请设置:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
keycloak:
|
||||||
|
production: true
|
||||||
|
hostname: keycloak.yourdomain.com
|
||||||
|
hostnameStrict: true
|
||||||
|
```
|
||||||
|
|
||||||
|
## 外部数据库
|
||||||
|
|
||||||
|
要使用外部数据库而不是嵌入式 PostgreSQL:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
postgres:
|
||||||
|
enabled: false
|
||||||
|
|
||||||
|
database:
|
||||||
|
type: postgres
|
||||||
|
host: postgres.example.com
|
||||||
|
port: 5432
|
||||||
|
name: keycloak
|
||||||
|
username: keycloak
|
||||||
|
password: your-password
|
||||||
|
```
|
||||||
|
|
||||||
|
## 文档
|
||||||
|
|
||||||
|
更多信息请参阅:
|
||||||
|
|
||||||
|
- [Keycloak 官方网站](https://www.keycloak.org)
|
||||||
|
- [Keycloak 文档](https://www.keycloak.org/documentation)
|
||||||
62
src/keycloak/values.yaml
Normal file
62
src/keycloak/values.yaml
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
# Keycloak Configuration
|
||||||
|
# https://github.com/CloudPirates-io/helm-charts/tree/main/charts/keycloak
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
keycloak:
|
||||||
|
adminUser: admin
|
||||||
|
adminPassword: admin-password # Change me!
|
||||||
|
hostname: ''
|
||||||
|
hostnameStrict: false
|
||||||
|
httpEnabled: true
|
||||||
|
httpsEnabled: false
|
||||||
|
production: false
|
||||||
|
extraArgs: []
|
||||||
|
|
||||||
|
database:
|
||||||
|
type: postgres
|
||||||
|
host: ''
|
||||||
|
port: ''
|
||||||
|
name: keycloak
|
||||||
|
username: keycloak
|
||||||
|
password: keycloak-db-password # Change me!
|
||||||
|
|
||||||
|
# Embedded PostgreSQL
|
||||||
|
postgres:
|
||||||
|
enabled: true
|
||||||
|
auth:
|
||||||
|
database: keycloak
|
||||||
|
username: ''
|
||||||
|
password: ''
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
httpPort: 8080
|
||||||
|
httpsPort: 8443
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: true
|
||||||
|
className: nginx
|
||||||
|
annotations: {}
|
||||||
|
hosts:
|
||||||
|
- host: keycloak.local
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
tls: []
|
||||||
|
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
cpu: '1'
|
||||||
|
memory: 1Gi
|
||||||
|
requests:
|
||||||
|
cpu: '0.5'
|
||||||
|
memory: 512Mi
|
||||||
|
|
||||||
|
persistence:
|
||||||
|
enabled: false
|
||||||
|
storageClass: ''
|
||||||
|
size: 1Gi
|
||||||
|
|
||||||
|
metrics:
|
||||||
|
enabled: false
|
||||||
@@ -1,14 +1,14 @@
|
|||||||
replicas: 3
|
replicas: 3
|
||||||
|
|
||||||
elasticsearchHosts: "http://elasticsearch:9200"
|
elasticsearchHosts: 'http://elasticsearch:9200'
|
||||||
|
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
cpu: "500m"
|
cpu: 500m
|
||||||
memory: "1Gi"
|
memory: 1Gi
|
||||||
limits:
|
limits:
|
||||||
cpu: "1000m"
|
cpu: 1000m
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
|
|
||||||
kibanaConfig:
|
kibanaConfig:
|
||||||
kibana.yml: |
|
kibana.yml: |
|
||||||
@@ -19,11 +19,11 @@ service:
|
|||||||
type: ClusterIP
|
type: ClusterIP
|
||||||
port: 5601
|
port: 5601
|
||||||
|
|
||||||
healthCheckPath: "/api/status"
|
healthCheckPath: /api/status
|
||||||
|
|
||||||
ingress:
|
ingress:
|
||||||
enabled: false
|
enabled: false
|
||||||
className: "nginx"
|
className: nginx
|
||||||
hosts:
|
hosts:
|
||||||
- host: kibana.example.com
|
- host: kibana.example.com
|
||||||
paths:
|
paths:
|
||||||
|
|||||||
@@ -3,47 +3,47 @@ langfuse:
|
|||||||
web:
|
web:
|
||||||
replicas: 3
|
replicas: 3
|
||||||
salt:
|
salt:
|
||||||
value: "salt-key" # Change me: $ openssl rand -base64 32
|
value: salt-key # Change me: $ openssl rand -base64 32
|
||||||
nextauth:
|
nextauth:
|
||||||
url: http://langfuse-web:3000 # Change me if you change the web service name or port
|
url: http://langfuse-web:3000 # Change me if you change the web service name or port
|
||||||
secret:
|
secret:
|
||||||
value: "secret-key" # Change me: $ openssl rand -hex 32
|
value: secret-key # Change me: $ openssl rand -hex 32
|
||||||
additionalEnv:
|
additionalEnv:
|
||||||
- name: "DATABASE_URL"
|
- name: DATABASE_URL
|
||||||
value: "postgres://postgres:wFvh4a6QdJ@postgres-postgresql.db:5432/postgres_langfuse"
|
value: 'postgres://postgres:wFvh4a6QdJ@postgres-postgresql.db:5432/postgres_langfuse'
|
||||||
encryptionKey:
|
encryptionKey:
|
||||||
value: "encryption-key" # Change me: $ openssl rand -hex 32
|
value: encryption-key # Change me: $ openssl rand -hex 32
|
||||||
|
|
||||||
postgresql:
|
postgresql:
|
||||||
deploy: false
|
deploy: false
|
||||||
directUrl: "postgres://postgres:wFvh4a6QdJ@postgres-postgresql.db:5432/postgres_langfuse"
|
directUrl: 'postgres://postgres:wFvh4a6QdJ@postgres-postgresql.db:5432/postgres_langfuse'
|
||||||
auth:
|
auth:
|
||||||
secretKeys:
|
secretKeys:
|
||||||
adminPasswordKey: "wFvh4a6QdJ"
|
adminPasswordKey: wFvh4a6QdJ
|
||||||
password: "wFvh4a6QdJ"
|
password: wFvh4a6QdJ
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
auth:
|
auth:
|
||||||
password: "FfuNDfCpeUUmmcD5GS7FMBm"
|
password: FfuNDfCpeUUmmcD5GS7FMBm
|
||||||
|
|
||||||
clickhouse:
|
clickhouse:
|
||||||
auth:
|
auth:
|
||||||
password: "FfuNDfCpeUUmmcD5GS7FMBm"
|
password: FfuNDfCpeUUmmcD5GS7FMBm
|
||||||
clusterEnabled: true
|
clusterEnabled: true
|
||||||
replicaCount: 3
|
replicaCount: 3
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
cpu: "500m"
|
cpu: 500m
|
||||||
limits:
|
limits:
|
||||||
memory: "4Gi"
|
memory: 4Gi
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
zookeeper:
|
zookeeper:
|
||||||
enabled: true
|
enabled: true
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
cpu: "500m"
|
cpu: 500m
|
||||||
limits:
|
limits:
|
||||||
memory: "4Gi"
|
memory: 4Gi
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
|
|||||||
16
src/mariadb/Makefile
Normal file
16
src/mariadb/Makefile
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
HELM_RELEASE_NAME ?= mariadb
|
||||||
|
HELM_APPLICATION_NAME ?= mariadb
|
||||||
|
HELM_NAMESPACE ?= mariadb
|
||||||
|
HELM_DIR ?= ./helm
|
||||||
|
HELM_CHART_VERSION ?= 0.14.1
|
||||||
|
HELM_VALUES_FILE ?= ./values.yaml
|
||||||
|
HELM_OCI_REGISTRY ?= docker.io
|
||||||
|
HELM_OCI_NAMESPACE ?= cloudpirates
|
||||||
|
HELM_OCI_USERNAME ?=
|
||||||
|
HELM_OCI_PASSWORD ?=
|
||||||
|
HELM_REPO_NAME ?=
|
||||||
|
HELM_REPO_URL ?=
|
||||||
|
HELM_CHART_REPO ?= oci://$(HELM_OCI_REGISTRY)/$(HELM_OCI_NAMESPACE)/$(HELM_APPLICATION_NAME)
|
||||||
|
HELM_LANE ?=
|
||||||
|
|
||||||
|
include ../_template/base.mk
|
||||||
65
src/mariadb/README.md
Normal file
65
src/mariadb/README.md
Normal file
@@ -0,0 +1,65 @@
|
|||||||
|
# MariaDB
|
||||||
|
|
||||||
|
## Introduction
|
||||||
|
|
||||||
|
MariaDB is a high-performance, open-source relational database server that is a drop-in replacement for MySQL. It supports both single-node and Galera Cluster deployments.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
To install MariaDB, run:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make install
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
After installation, verify the deployment:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl get pods -n mariadb
|
||||||
|
```
|
||||||
|
|
||||||
|
To connect to MariaDB from within the cluster:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl exec -it -n mariadb deploy/mariadb -- mysql -u root -p
|
||||||
|
```
|
||||||
|
|
||||||
|
To access MariaDB from outside the cluster, port-forward the service:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl port-forward svc/mariadb 3306:3306 -n mariadb
|
||||||
|
```
|
||||||
|
|
||||||
|
Then connect using:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
mysql -h 127.0.0.1 -P 3306 -u root -p
|
||||||
|
```
|
||||||
|
|
||||||
|
## Configuration
|
||||||
|
|
||||||
|
You can customize the MariaDB configuration by editing `values.yaml`:
|
||||||
|
|
||||||
|
- `auth`: Configure database authentication (root password, custom user)
|
||||||
|
- `galera`: Enable Galera Cluster mode for high availability
|
||||||
|
- `persistence`: Configure PVC storage settings
|
||||||
|
- `metrics`: Enable Prometheus metrics exporter
|
||||||
|
|
||||||
|
## Galera Cluster
|
||||||
|
|
||||||
|
To enable Galera Cluster mode, set:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
galera:
|
||||||
|
enabled: true
|
||||||
|
replicaCount: 3
|
||||||
|
```
|
||||||
|
|
||||||
|
## Documentation
|
||||||
|
|
||||||
|
For more information, see:
|
||||||
|
|
||||||
|
- [MariaDB Official Website](https://mariadb.org)
|
||||||
|
- [MariaDB Documentation](https://mariadb.com/kb/en/documentation/)
|
||||||
65
src/mariadb/README.zh.md
Normal file
65
src/mariadb/README.zh.md
Normal file
@@ -0,0 +1,65 @@
|
|||||||
|
# MariaDB
|
||||||
|
|
||||||
|
## 简介
|
||||||
|
|
||||||
|
MariaDB 是一个高性能的开源关系数据库服务器,是 MySQL 的直接替代品。它支持单节点和 Galera 集群部署。
|
||||||
|
|
||||||
|
## 安装
|
||||||
|
|
||||||
|
要安装 MariaDB,请运行:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make install
|
||||||
|
```
|
||||||
|
|
||||||
|
## 使用
|
||||||
|
|
||||||
|
安装后,验证部署:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl get pods -n mariadb
|
||||||
|
```
|
||||||
|
|
||||||
|
要从集群内部连接到 MariaDB:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl exec -it -n mariadb deploy/mariadb -- mysql -u root -p
|
||||||
|
```
|
||||||
|
|
||||||
|
要从集群外部访问 MariaDB,请端口转发服务:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl port-forward svc/mariadb 3306:3306 -n mariadb
|
||||||
|
```
|
||||||
|
|
||||||
|
然后使用以下方式连接:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
mysql -h 127.0.0.1 -P 3306 -u root -p
|
||||||
|
```
|
||||||
|
|
||||||
|
## 配置
|
||||||
|
|
||||||
|
您可以通过编辑 `values.yaml` 来自定义 MariaDB 配置:
|
||||||
|
|
||||||
|
- `auth`: 配置数据库认证(root 密码、自定义用户)
|
||||||
|
- `galera`: 启用 Galera 集群模式以实现高可用性
|
||||||
|
- `persistence`: 配置 PVC 存储设置
|
||||||
|
- `metrics`: 启用 Prometheus 指标导出器
|
||||||
|
|
||||||
|
## Galera 集群
|
||||||
|
|
||||||
|
要启用 Galera 集群模式,请设置:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
galera:
|
||||||
|
enabled: true
|
||||||
|
replicaCount: 3
|
||||||
|
```
|
||||||
|
|
||||||
|
## 文档
|
||||||
|
|
||||||
|
更多信息请参阅:
|
||||||
|
|
||||||
|
- [MariaDB 官方网站](https://mariadb.org)
|
||||||
|
- [MariaDB 文档](https://mariadb.com/kb/en/documentation/)
|
||||||
33
src/mariadb/values.yaml
Normal file
33
src/mariadb/values.yaml
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
# MariaDB Configuration
|
||||||
|
# https://github.com/CloudPirates-io/helm-charts/tree/main/charts/mariadb
|
||||||
|
|
||||||
|
auth:
|
||||||
|
enabled: true
|
||||||
|
rootPassword: mariadb-root-password # Change me!
|
||||||
|
database: mariadb
|
||||||
|
username: mariadb
|
||||||
|
password: mariadb-password # Change me!
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
port: 3306
|
||||||
|
|
||||||
|
persistence:
|
||||||
|
enabled: true
|
||||||
|
storageClass: local-path
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
size: 8Gi
|
||||||
|
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
cpu: '1'
|
||||||
|
memory: 1Gi
|
||||||
|
requests:
|
||||||
|
cpu: '0.1'
|
||||||
|
memory: 512Mi
|
||||||
|
|
||||||
|
# Galera Cluster Configuration
|
||||||
|
galera:
|
||||||
|
enabled: false
|
||||||
|
replicaCount: 3
|
||||||
@@ -33,11 +33,11 @@ standalone:
|
|||||||
enabled: true
|
enabled: true
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
persistence:
|
persistence:
|
||||||
persistentVolumeClaim:
|
persistentVolumeClaim:
|
||||||
storageClass: local-path
|
storageClass: local-path
|
||||||
@@ -51,7 +51,7 @@ minio:
|
|||||||
mode: standalone
|
mode: standalone
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
existingClaim: ""
|
existingClaim: ''
|
||||||
storageClass: local-path
|
storageClass: local-path
|
||||||
accessMode: ReadWriteOnce
|
accessMode: ReadWriteOnce
|
||||||
size: 500Gi
|
size: 500Gi
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ replicaCount: 3
|
|||||||
|
|
||||||
auth:
|
auth:
|
||||||
rootUser: admin
|
rootUser: admin
|
||||||
rootPassword: "root-password" # Change me: $ openssl rand -base64 12
|
rootPassword: root-password # Change me: $ openssl rand -base64 12
|
||||||
|
|
||||||
ingress:
|
ingress:
|
||||||
enabled: true
|
enabled: true
|
||||||
@@ -20,8 +20,8 @@ persistence:
|
|||||||
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
|
|||||||
@@ -3,12 +3,12 @@ replicaCount: 3
|
|||||||
replicaSet:
|
replicaSet:
|
||||||
enabled: true
|
enabled: true
|
||||||
name: rs0
|
name: rs0
|
||||||
key: "qJlSywRHAWOysZaow3uE5f3BQAY/1ml/" # change me!
|
key: qJlSywRHAWOysZaow3uE5f3BQAY/1ml/ # change me!
|
||||||
|
|
||||||
auth:
|
auth:
|
||||||
enabled: true
|
enabled: true
|
||||||
rootUsername: admin
|
rootUsername: admin
|
||||||
rootPassword: "password" # Change me!
|
rootPassword: password # Change me!
|
||||||
|
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
@@ -16,8 +16,8 @@ persistence:
|
|||||||
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
|
|||||||
16
src/nginx/Makefile
Normal file
16
src/nginx/Makefile
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
HELM_RELEASE_NAME ?= nginx
|
||||||
|
HELM_APPLICATION_NAME ?= nginx
|
||||||
|
HELM_NAMESPACE ?= nginx
|
||||||
|
HELM_DIR ?= ./helm
|
||||||
|
HELM_CHART_VERSION ?= 0.6.0
|
||||||
|
HELM_VALUES_FILE ?= ./values.yaml
|
||||||
|
HELM_OCI_REGISTRY ?= docker.io
|
||||||
|
HELM_OCI_NAMESPACE ?= cloudpirates
|
||||||
|
HELM_OCI_USERNAME ?=
|
||||||
|
HELM_OCI_PASSWORD ?=
|
||||||
|
HELM_REPO_NAME ?=
|
||||||
|
HELM_REPO_URL ?=
|
||||||
|
HELM_CHART_REPO ?= oci://$(HELM_OCI_REGISTRY)/$(HELM_OCI_NAMESPACE)/$(HELM_APPLICATION_NAME)
|
||||||
|
HELM_LANE ?=
|
||||||
|
|
||||||
|
include ../_template/base.mk
|
||||||
45
src/nginx/README.md
Normal file
45
src/nginx/README.md
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
# Nginx
|
||||||
|
|
||||||
|
## Introduction
|
||||||
|
|
||||||
|
Nginx is a high-performance HTTP server and reverse proxy, known for its stability, rich feature set, simple configuration, and low resource consumption.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
To install Nginx, run:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make install
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
After installation, verify the deployment:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl get pods -n nginx
|
||||||
|
```
|
||||||
|
|
||||||
|
To access Nginx, port-forward the service:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl port-forward svc/nginx 8080:80 -n nginx
|
||||||
|
```
|
||||||
|
|
||||||
|
Then access at <http://localhost:8080>
|
||||||
|
|
||||||
|
## Configuration
|
||||||
|
|
||||||
|
You can customize the Nginx configuration by editing `values.yaml`:
|
||||||
|
|
||||||
|
- `config`: Custom nginx.conf content
|
||||||
|
- `serverConfig`: Custom server block configuration
|
||||||
|
- `staticSiteConfigmap`: Use an existing ConfigMap with static site content
|
||||||
|
- `ingress`: Configure ingress for external access
|
||||||
|
|
||||||
|
## Documentation
|
||||||
|
|
||||||
|
For more information, see:
|
||||||
|
|
||||||
|
- [Nginx Official Website](https://www.nginx.com)
|
||||||
|
- [Nginx Documentation](https://nginx.org/en/docs/)
|
||||||
45
src/nginx/README.zh.md
Normal file
45
src/nginx/README.zh.md
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
# Nginx
|
||||||
|
|
||||||
|
## 简介
|
||||||
|
|
||||||
|
Nginx 是一个高性能的 HTTP 服务器和反向代理,以其稳定性、丰富的功能集、简单的配置和低资源消耗而闻名。
|
||||||
|
|
||||||
|
## 安装
|
||||||
|
|
||||||
|
要安装 Nginx,请运行:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make install
|
||||||
|
```
|
||||||
|
|
||||||
|
## 使用
|
||||||
|
|
||||||
|
安装后,验证部署:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl get pods -n nginx
|
||||||
|
```
|
||||||
|
|
||||||
|
要访问 Nginx,请端口转发服务:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl port-forward svc/nginx 8080:80 -n nginx
|
||||||
|
```
|
||||||
|
|
||||||
|
然后在 <http://localhost:8080> 访问
|
||||||
|
|
||||||
|
## 配置
|
||||||
|
|
||||||
|
您可以通过编辑 `values.yaml` 来自定义 Nginx 配置:
|
||||||
|
|
||||||
|
- `config`: 自定义 nginx.conf 内容
|
||||||
|
- `serverConfig`: 自定义服务器块配置
|
||||||
|
- `staticSiteConfigmap`: 使用带有静态站点内容的现有 ConfigMap
|
||||||
|
- `ingress`: 配置 ingress 以进行外部访问
|
||||||
|
|
||||||
|
## 文档
|
||||||
|
|
||||||
|
更多信息请参阅:
|
||||||
|
|
||||||
|
- [Nginx 官方网站](https://www.nginx.com)
|
||||||
|
- [Nginx 文档](https://nginx.org/en/docs/)
|
||||||
31
src/nginx/values.yaml
Normal file
31
src/nginx/values.yaml
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
# Nginx Configuration
|
||||||
|
# https://github.com/CloudPirates-io/helm-charts/tree/main/charts/nginx
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
|
|
||||||
|
service:
|
||||||
|
type: ClusterIP
|
||||||
|
ports:
|
||||||
|
- port: 80
|
||||||
|
targetPort: http
|
||||||
|
protocol: TCP
|
||||||
|
name: http
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: true
|
||||||
|
className: nginx
|
||||||
|
annotations: {}
|
||||||
|
hosts:
|
||||||
|
- host: nginx.local
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
tls: []
|
||||||
|
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
cpu: 200m
|
||||||
|
memory: 256Mi
|
||||||
|
requests:
|
||||||
|
cpu: 50m
|
||||||
|
memory: 128Mi
|
||||||
@@ -36,11 +36,11 @@ config:
|
|||||||
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
|
|
||||||
service:
|
service:
|
||||||
type: ClusterIP
|
type: ClusterIP
|
||||||
|
|||||||
@@ -27,21 +27,21 @@ service:
|
|||||||
auth:
|
auth:
|
||||||
enableAuth: false
|
enableAuth: false
|
||||||
secret:
|
secret:
|
||||||
- key: "PHOENIX_SECRET"
|
- key: PHOENIX_SECRET
|
||||||
value: "phoenix-secret" # Change me!
|
value: phoenix-secret # Change me!
|
||||||
- key: "PHOENIX_ADMIN_SECRET"
|
- key: PHOENIX_ADMIN_SECRET
|
||||||
value: "phoenix-admin-secret" # Change me!
|
value: phoenix-admin-secret # Change me!
|
||||||
- key: "PHOENIX_POSTGRES_PASSWORD"
|
- key: PHOENIX_POSTGRES_PASSWORD
|
||||||
value: "phoenix-postgres-password" # Change me!
|
value: phoenix-postgres-password # Change me!
|
||||||
- key: "PHOENIX_SMTP_PASSWORD"
|
- key: PHOENIX_SMTP_PASSWORD
|
||||||
value: "phoenix-smtp-password" # Change me!
|
value: phoenix-smtp-password # Change me!
|
||||||
- key: "PHOENIX_DEFAULT_ADMIN_INITIAL_PASSWORD"
|
- key: PHOENIX_DEFAULT_ADMIN_INITIAL_PASSWORD
|
||||||
value: "phoenix-default-admin-initial-password" # Change me!
|
value: phoenix-default-admin-initial-password # Change me!
|
||||||
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
|
|||||||
16
src/rabbitmq-cluster-operator/Makefile
Normal file
16
src/rabbitmq-cluster-operator/Makefile
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
HELM_RELEASE_NAME ?= rabbitmq-cluster-operator
|
||||||
|
HELM_APPLICATION_NAME ?= rabbitmq-cluster-operator
|
||||||
|
HELM_NAMESPACE ?= rabbitmq-cluster-operator
|
||||||
|
HELM_DIR ?= ./helm
|
||||||
|
HELM_CHART_VERSION ?= 0.2.0
|
||||||
|
HELM_VALUES_FILE ?= ./values.yaml
|
||||||
|
HELM_OCI_REGISTRY ?= docker.io
|
||||||
|
HELM_OCI_NAMESPACE ?= cloudpirates
|
||||||
|
HELM_OCI_USERNAME ?=
|
||||||
|
HELM_OCI_PASSWORD ?=
|
||||||
|
HELM_REPO_NAME ?=
|
||||||
|
HELM_REPO_URL ?=
|
||||||
|
HELM_CHART_REPO ?= oci://$(HELM_OCI_REGISTRY)/$(HELM_OCI_NAMESPACE)/$(HELM_APPLICATION_NAME)
|
||||||
|
HELM_LANE ?=
|
||||||
|
|
||||||
|
include ../_template/base.mk
|
||||||
55
src/rabbitmq-cluster-operator/README.md
Normal file
55
src/rabbitmq-cluster-operator/README.md
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
# RabbitMQ Cluster Operator
|
||||||
|
|
||||||
|
## Introduction
|
||||||
|
|
||||||
|
The RabbitMQ Cluster Operator is a Kubernetes operator that automates the deployment and management of RabbitMQ clusters on Kubernetes.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
To install RabbitMQ Cluster Operator, run:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make install
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
After installation, verify the deployment:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl get pods -n rabbitmq-cluster-operator
|
||||||
|
```
|
||||||
|
|
||||||
|
To create a RabbitMQ cluster, apply a RabbitmqCluster custom resource:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
apiVersion: rabbitmq.com/v1beta1
|
||||||
|
kind: RabbitmqCluster
|
||||||
|
metadata:
|
||||||
|
name: my-rabbitmq
|
||||||
|
namespace: default
|
||||||
|
spec:
|
||||||
|
replicas: 3
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 500m
|
||||||
|
memory: 1Gi
|
||||||
|
limits:
|
||||||
|
cpu: 1
|
||||||
|
memory: 2Gi
|
||||||
|
```
|
||||||
|
|
||||||
|
To access the RabbitMQ Management UI, port-forward the service:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl port-forward svc/my-rabbitmq 15672:15672 -n default
|
||||||
|
```
|
||||||
|
|
||||||
|
Then access at <http://localhost:15672>
|
||||||
|
|
||||||
|
## Documentation
|
||||||
|
|
||||||
|
For more information, see:
|
||||||
|
|
||||||
|
- [RabbitMQ Cluster Operator GitHub](https://github.com/rabbitmq/cluster-operator)
|
||||||
|
- [RabbitMQ Documentation](https://www.rabbitmq.com/kubernetes/operator/operator-overview.html)
|
||||||
55
src/rabbitmq-cluster-operator/README.zh.md
Normal file
55
src/rabbitmq-cluster-operator/README.zh.md
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
# RabbitMQ Cluster Operator
|
||||||
|
|
||||||
|
## 简介
|
||||||
|
|
||||||
|
RabbitMQ Cluster Operator 是一个 Kubernetes 运营商,用于在 Kubernetes 上自动部署和管理 RabbitMQ 集群。
|
||||||
|
|
||||||
|
## 安装
|
||||||
|
|
||||||
|
要安装 RabbitMQ Cluster Operator,请运行:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make install
|
||||||
|
```
|
||||||
|
|
||||||
|
## 使用
|
||||||
|
|
||||||
|
安装后,验证部署:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl get pods -n rabbitmq-cluster-operator
|
||||||
|
```
|
||||||
|
|
||||||
|
要创建 RabbitMQ 集群,请应用 RabbitmqCluster 自定义资源:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
apiVersion: rabbitmq.com/v1beta1
|
||||||
|
kind: RabbitmqCluster
|
||||||
|
metadata:
|
||||||
|
name: my-rabbitmq
|
||||||
|
namespace: default
|
||||||
|
spec:
|
||||||
|
replicas: 3
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 500m
|
||||||
|
memory: 1Gi
|
||||||
|
limits:
|
||||||
|
cpu: 1
|
||||||
|
memory: 2Gi
|
||||||
|
```
|
||||||
|
|
||||||
|
要访问 RabbitMQ 管理 UI,请端口转发服务:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl port-forward svc/my-rabbitmq 15672:15672 -n default
|
||||||
|
```
|
||||||
|
|
||||||
|
然后在 <http://localhost:15672> 访问
|
||||||
|
|
||||||
|
## 文档
|
||||||
|
|
||||||
|
更多信息请参阅:
|
||||||
|
|
||||||
|
- [RabbitMQ Cluster Operator GitHub](https://github.com/rabbitmq/cluster-operator)
|
||||||
|
- [RabbitMQ 文档](https://www.rabbitmq.com/kubernetes/operator/operator-overview.html)
|
||||||
27
src/rabbitmq-cluster-operator/values.yaml
Normal file
27
src/rabbitmq-cluster-operator/values.yaml
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
# RabbitMQ Cluster Operator Configuration
|
||||||
|
# https://github.com/CloudPirates-io/helm-charts/tree/main/charts/rabbitmq-cluster-operator
|
||||||
|
|
||||||
|
clusterOperator:
|
||||||
|
replicaCount: 1
|
||||||
|
watchAllNamespaces: true
|
||||||
|
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
cpu: 500m
|
||||||
|
memory: 512Mi
|
||||||
|
requests:
|
||||||
|
cpu: 100m
|
||||||
|
memory: 128Mi
|
||||||
|
|
||||||
|
msgTopologyOperator:
|
||||||
|
enabled: true
|
||||||
|
replicaCount: 1
|
||||||
|
watchAllNamespaces: true
|
||||||
|
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
cpu: 500m
|
||||||
|
memory: 512Mi
|
||||||
|
requests:
|
||||||
|
cpu: 100m
|
||||||
|
memory: 128Mi
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
replicaCount: 3
|
replicaCount: 3
|
||||||
|
|
||||||
auth:
|
auth:
|
||||||
password: "password" # Change me!
|
password: password # Change me!
|
||||||
erlangCookie: "erlang-cookie" # Change me!
|
erlangCookie: erlang-cookie # Change me!
|
||||||
|
|
||||||
ingress:
|
ingress:
|
||||||
enabled: true
|
enabled: true
|
||||||
@@ -20,8 +20,8 @@ persistence:
|
|||||||
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ service:
|
|||||||
|
|
||||||
auth:
|
auth:
|
||||||
enabled: true
|
enabled: true
|
||||||
password: "password" # Change me!
|
password: password # Change me!
|
||||||
|
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
@@ -13,8 +13,8 @@ persistence:
|
|||||||
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
|
|||||||
@@ -8,12 +8,12 @@ persistence:
|
|||||||
|
|
||||||
auth:
|
auth:
|
||||||
enabled: true
|
enabled: true
|
||||||
password: "password" # Change me!
|
password: password # Change me!
|
||||||
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
|
|||||||
@@ -7,8 +7,8 @@ service:
|
|||||||
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "1"
|
cpu: '1'
|
||||||
memory: "2Gi"
|
memory: 2Gi
|
||||||
requests:
|
requests:
|
||||||
cpu: "0.1"
|
cpu: '0.1'
|
||||||
memory: "512Mi"
|
memory: 512Mi
|
||||||
|
|||||||
Reference in New Issue
Block a user