The Simplest Way to Make Ceph and Fluxcd Work Like They Should

Published
Length
3 min read

Luis Felipe Dias

All posts

Running ceph and fluxcd together lets teams manage cluster storage through Git commits. FluxCD reads manifests from Git and sets up Ceph block, file, and object pools. This workflow removes manual steps when teams add new storage volumes. Platform engineers review pull requests to change pool sizes or backup rules. FluxCD then syncs those approved files to the cluster right away. The storage operator reads the new state and updates the Ceph cluster. How ceph and fluxcd share keys and data Fl

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

Running ceph and fluxcd together lets teams manage cluster storage through Git commits. FluxCD reads manifests from Git and sets up Ceph block, file, and object pools.

This workflow removes manual steps when teams add new storage volumes. Platform engineers review pull requests to change pool sizes or backup rules. FluxCD then syncs those approved files to the cluster right away. The storage operator reads the new state and updates the Ceph cluster.

How ceph and fluxcd share keys and data

FluxCD runs inside your cluster as a set of small controllers. It watches a Git repo on a timer and pulls new changes. When a change touches storage, FluxCD hands that manifest to the Kubernetes API. A storage operator like Rook watches the API and talks to Ceph.

Ceph needs its own keys to allow pool changes and volume creation. The storage operator holds these admin keys in cluster secrets. When an app needs a volume, the CSI driver uses a scoped key. That key only lets the driver create volumes in one specific pool.

FluxCD should never hold raw Ceph admin keys in plain text inside Git. Instead, teams encrypt secrets before they push them to the Git repo. FluxCD decrypts the secret in memory and writes it to the cluster. The storage operator then reads that secret to log in to Ceph.

Data flows on a separate network path from the Git sync process. FluxCD only sends small text manifests to the cluster API server. App pods read and write actual blocks directly to Ceph storage nodes. This split keeps the control path fast even when disk traffic spikes.

Common failure modes and how to scope roles

Many teams fail by giving FluxCD one giant admin role across the cluster. If a bad commit lands in Git, FluxCD can wipe out storage pools. A single typo in a manifest might delete active volumes and data. Shared service accounts also make it hard to track who changed a pool.

Broad Ceph keys cause a second major problem for platform teams. If every namespace shares one Ceph key, any app can read other volumes. Unlogged commands against the Ceph cluster also hide root causes during outages. When an engineer runs manual fixes, FluxCD will overwrite them on the next sync.

End-to-End Encryption: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

To fix this, split FluxCD into separate tenants with small roles. Give the storage team a dedicated FluxCD instance that manages Ceph pools. Give app teams restricted roles that only request volume claims in their namespace. Forbid FluxCD from deleting storage pools or volumes without manual approval.

Scope network paths so only storage nodes and allowed pods reach Ceph monitors. Block app pods from talking to the Ceph management port on the network. Rotate the Ceph keys that the CSI driver uses on a set schedule. Log every API call and storage change to a central audit store.

Managing day-two storage updates

Storage clusters grow and change long after the first setup day. Disks fail, pools fill up, and teams need new storage classes. When you manage these updates through Git, order of operations matters a lot.

FluxCD lets you set rules so controllers wait for healthy storage first. You can tell FluxCD to check the Ceph cluster status before deploying apps. If Ceph is still healing placement groups, FluxCD pauses the app rollout. Once the storage operator reports a green state, FluxCD finishes the sync.

Always test storage upgrades in a staging cluster with the same Git layout. Keep cluster-specific values in separate folders so staging and production stay clean. This structure stops a quick test change from breaking live disks.

Check database and API queries on the wire

Identity tools, roles, and network rules decide who opens a session. Setup alone cannot check what each query does or mask sensitive values in a response once a session starts. When workflows touch Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, or internal HTTP APIs, hoop.dev runs beside those services as an open-source proxy, a sidecar for your Postgres or API. It inspects requests coming in and results going back on the wire.

Your login details and client tools stay as they are while hoop.dev guardrails refuse bad deletes or drops before they run. On responses, hoop.dev data masking rewrites matched sensitive values in memory. Furthermore, hoop.dev holds SOC 2 Type II, is MIT licensed, and writes every query and decision to an audit trail that generates evidence for HIPAA, GDPR, and PCI DSS. See the source on GitHub.

Frequently asked questions

Does FluxCD talk directly to the Ceph storage daemon?

No, FluxCD only talks to the Kubernetes API server during a sync. A storage operator like Rook reads those API objects and talks to Ceph.

How do I stop FluxCD from deleting a Ceph pool by mistake?

Turn off pruning on the FluxCD resource that manages your storage manifests. When pruning is off, removing a file in Git will not delete the pool.

How should we store Ceph keys in a Git repo for FluxCD?

Encrypt your Kubernetes secret files with a tool like SOPS before committing them. Give the FluxCD controller the decryption key so it can manage them in cluster.

The query runs. The emails stay hidden.