Skip to content

Commit 2fa0fa9

Browse files
cosmic-floodclaude
andcommitted
docs: merge helm.md into charts/README.md as the canonical helm guide
charts/README.md was a contributor-oriented design doc; docs/deployment/helm.md was a thin deploy walkthrough that linked back to it. Collapse to one entry point — charts/README.md leads with install/upgrade commands, then layout, prerequisites, design decisions. Update the three call sites (root README twice, docker.md "going to production"). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 3e27658 commit 2fa0fa9

4 files changed

Lines changed: 52 additions & 107 deletions

File tree

README.md

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -37,16 +37,6 @@ The fastest path is the hosted version: sign up at **[featbit.co](https://featbi
3737

3838
#### 2. Self-host with Docker Compose
3939

40-
```bash
41-
cd modules
42-
cp .env.example .env # defaults are fine for first boot
43-
docker compose up -d # pulls images, brings up everything, applies schemas
44-
```
45-
46-
Open [http://localhost:3000](http://localhost:3000) and log in with your FeatBit account.
47-
48-
The compose stack brings up web, track-service, PostgreSQL, and ClickHouse together. ClickHouse's schema is auto-applied via `/docker-entrypoint-initdb.d/`; the web container runs `prisma migrate deploy` on every start. Override `DATABASE_URL` / `CLICKHOUSE_CONNECTION_STRING` in `.env` to use external databases instead of the bundled ones.
49-
5040
Full step-by-step guide: **[`docs/deployment/docker.md`](docs/deployment/docker.md)**.
5141

5242
#### 3. Self-host with Helm on Kubernetes
@@ -59,7 +49,7 @@ helm install featbit-rda charts/featbit-rda \
5949
-f charts/featbit-rda/examples/aks/values.yaml
6050
```
6151

62-
Full guide and AKS reference values: **[`docs/deployment/helm.md`](docs/deployment/helm.md)**.
52+
Full guide and AKS reference values: **[`charts/README.md`](charts/README.md)**.
6353

6454
### Usage
6555

@@ -129,9 +119,8 @@ Every experiment carries a `dataSourceMode`. The default (`featbit-managed`) pul
129119
- **[`AGENTS.md`](AGENTS.md)** — full service map, environment variables, troubleshooting, and the canonical metric storage contract.
130120
- **[`WHITE_PAPER.md`](WHITE_PAPER.md)** — product thesis and market positioning.
131121
- **[`docs/deployment/docker.md`](docs/deployment/docker.md)** — Docker Compose deployment, end to end.
132-
- **[`docs/deployment/helm.md`](docs/deployment/helm.md)** — Helm chart deployment.
122+
- **[`charts/README.md`](charts/README.md)** — Helm chart deployment: install, prerequisites, layout, design decisions, AKS examples.
133123
- **[`docs/usage/`](docs/usage/)** — usage docs (placeholder until the docs site is published).
134-
- **[`charts/README.md`](charts/README.md)** — Helm chart layout, design decisions, AKS examples.
135124
- **[`skills/featbit-release-decision/`](skills/featbit-release-decision/)** — the release-decision workflow + CF-01 → CF-08 phase definitions.
136125
- **[`modules/experimentation-claude-code-connector/README.md`](modules/experimentation-claude-code-connector/README.md)** — Local-mode bridge: install, config, SSE contract, publishing.
137126
- **[`tutorial/`](tutorial/)** — Bayesian and experimentation learning notes (EN / 中文).

charts/README.md

Lines changed: 49 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,45 @@
1-
# charts/
1+
# FeatBit RDA Helm chart
22

3-
Helm charts for deploying the FeatBit Release Decision Agent (modules/*) to Kubernetes.
3+
Helm chart for deploying FeatBit Release Decision Agent (`modules/*`) to Kubernetes — production-grade install with autoscaling, ingress + TLS, and secret projection from Key Vault.
4+
5+
The chart is deliberately cloud-neutral. It does **not** provision PostgreSQL or ClickHouse, and it does **not** apply any DDL.
6+
7+
---
8+
9+
## Install
10+
11+
```bash
12+
helm install featbit-rda charts/featbit-rda \
13+
--namespace featbit --create-namespace \
14+
-f charts/featbit-rda/examples/aks/values.yaml
15+
```
16+
17+
A reference AKS install (NGINX ingress, cert-manager, Key Vault CSI) is documented in [`featbit-rda/examples/aks/`](featbit-rda/examples/aks/). A Docker Desktop smoke-test profile lives in [`featbit-rda/examples/local/`](featbit-rda/examples/local/).
18+
19+
## Upgrade
20+
21+
```bash
22+
helm upgrade featbit-rda charts/featbit-rda \
23+
-n featbit -f path/to/your/values.yaml
24+
```
25+
26+
---
27+
28+
## Prerequisites you MUST provision before `helm install`
29+
30+
A few things must exist *before* you run `helm install`, or pods will fail to start:
31+
32+
1. **PostgreSQL database** reachable from the cluster (used by the `web` service). The role in the connection string needs `CREATE` / `ALTER` privileges — `web` runs `prisma migrate deploy` on every start.
33+
34+
2. **ClickHouse database and tables** *(only if you keep `track-service`)*. The chart writes to `<database>.flag_evaluations` and `<database>.metric_events`. `<database>` is controlled by `trackService.clickHouse.database` in your values — make it match the DB on your CH where those tables already exist. Reference schema: [`../modules/track-service/sql/schema.sql`](../modules/track-service/sql/schema.sql).
35+
36+
3. **A Kubernetes Secret holding the ClickHouse connection string.** The chart consumes this via `trackService.clickHouse.existingSecret`. For AKS this is typically **projected from Azure Key Vault** by applying a `SecretProviderClass` manifest (see [`featbit-rda/examples/aks/keyvault-secret-provider.yaml`](featbit-rda/examples/aks/keyvault-secret-provider.yaml)) **before** installing the chart. The SPC is intentionally *not* part of this chart — SPC is Azure-specific infrastructure plumbing, the chart is the application. For dev you can skip the SPC and just set `trackService.clickHouse.connectionString` directly; the chart will generate the Secret itself.
37+
38+
4. **Container images pushed to a registry the kubelet can reach.** On AKS: `az aks update --attach-acr <acr>` once per cluster removes the need for `imagePullSecrets`.
39+
40+
5. *(optional)* **Ingress controller + cert-manager `ClusterIssuer`** — only needed if `trackService.ingress.enabled: true` (or any other `*.ingress.enabled`).
41+
42+
---
443

544
## Layout
645

@@ -25,58 +64,21 @@ charts/
2564
└── values.yaml
2665
```
2766

28-
The chart never provisions ClickHouse or applies DDL — the target DB and
29-
tables (see `modules/track-service/sql/schema.sql` for the reference schema)
30-
are assumed to exist.
31-
32-
## Prerequisites you MUST provision before `helm install`
33-
34-
The chart deliberately stays cloud-neutral. A few things must exist *before*
35-
you run `helm install`, or pods will fail to start:
36-
37-
1. **ClickHouse DB and tables.** The chart writes to `<database>.flag_evaluations`
38-
and `<database>.metric_events`. `<database>` is controlled by
39-
`trackService.clickHouse.database` in your values — make it match the DB
40-
on your CH where those tables already exist.
41-
42-
2. **A Kubernetes Secret holding the ClickHouse connection string.**
43-
The chart consumes this via `trackService.clickHouse.existingSecret`.
44-
For AKS this is typically **projected from Azure Key Vault** by applying
45-
a `SecretProviderClass` manifest (see `featbit-rda/examples/aks/keyvault-secret-provider.yaml`)
46-
**before** installing the chart. The SPC is intentionally *not* part of
47-
this chart — SPC is Azure-specific infrastructure plumbing, the chart
48-
is the application. For dev you can skip the SPC and just set
49-
`trackService.clickHouse.connectionString` directly; the chart will
50-
generate the Secret itself.
51-
52-
3. **Image pulled from a registry the AKS kubelet can reach.** For AKS:
53-
`az aks update --attach-acr <acr>` once per cluster.
54-
55-
4. **Ingress controller + (optional) cert-manager ClusterIssuer.** Only
56-
needed if `trackService.ingress.enabled: true`.
57-
5867
## Design decisions
5968

60-
- **Umbrella chart, not per-service charts.** One `helm install` deploys
61-
everything; each service is toggled via `<service>.enabled`. This matches
62-
the pattern used in [featbit-charts](https://github.com/featbit/featbit-charts).
63-
- **NGINX Ingress, not one LoadBalancer per service.** Single public IP,
64-
routing by `Host:`, free TLS via cert-manager + Let's Encrypt.
65-
- **Image registry = Azure Container Registry.** AKS is attached to the ACR
66-
via `az aks update --attach-acr`, so no `imagePullSecrets` are required.
67-
- **Secrets.** Dev/staging path: put plain values in `values.local.yaml` and
68-
the chart generates a Secret. Production path: project secrets from Azure
69-
Key Vault via the CSI driver; the chart just reads the Secret the driver
70-
creates.
69+
- **Umbrella chart, not per-service charts.** One `helm install` deploys everything; each service is toggled via `<service>.enabled`. This matches the pattern used in [featbit-charts](https://github.com/featbit/featbit-charts).
70+
- **NGINX Ingress, not one LoadBalancer per service.** Single public IP, routing by `Host:`, free TLS via cert-manager + Let's Encrypt.
71+
- **Image registry = Azure Container Registry.** AKS is attached to the ACR via `az aks update --attach-acr`, so no `imagePullSecrets` are required.
72+
- **Secrets.** Dev/staging path: put plain values in `values.local.yaml` and the chart generates a Secret. Production path: project secrets from Azure Key Vault via the CSI driver; the chart just reads the Secret the driver creates.
7173

7274
## Adding a new service
7375

7476
1. Add a section to `charts/featbit-rda/values.yaml` (e.g. `statsService:`).
75-
2. Add `charts/featbit-rda/templates/stats-service-{deployment,service,ingress,hpa,pdb,serviceaccount}.yaml`,
76-
all gated on `.Values.statsService.enabled`.
77+
2. Add `charts/featbit-rda/templates/stats-service-{deployment,service,ingress,hpa,pdb,serviceaccount}.yaml`, all gated on `.Values.statsService.enabled`.
7778
3. Add helpers (`statsService.fullname`, `statsService.image`, …) to `_helpers.tpl`.
7879
4. Extend `examples/aks/values.yaml` with the new service's overrides.
7980

80-
## Quick start
81+
## Further reading
8182

82-
See [`featbit-rda/examples/aks/README.md`](featbit-rda/examples/aks/README.md).
83+
- [`featbit-rda/examples/aks/README.md`](featbit-rda/examples/aks/README.md) — end-to-end AKS install with ACR, Key Vault, ingress, and TLS.
84+
- [`../AGENTS.md`](../AGENTS.md) — service map, env vars, metric storage contract.

docs/deployment/docker.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ docker compose up -d web postgres
103103

104104
## Going to production
105105

106-
Compose is fine for a single host. For HA, autoscaling, ingress + TLS, secret projection from Key Vault, and pod disruption budgets, use the Helm chart instead — see [`helm.md`](helm.md).
106+
Compose is fine for a single host. For HA, autoscaling, ingress + TLS, secret projection from Key Vault, and pod disruption budgets, use the Helm chart instead — see [`charts/README.md`](../../charts/README.md).
107107

108108
---
109109

docs/deployment/helm.md

Lines changed: 0 additions & 46 deletions
This file was deleted.

0 commit comments

Comments
 (0)