The Simplest Way to Make Kuma and Metabase Work Like They Should

Published
Length
3 min read

Luis Felipe Dias

All posts

You pair Kuma and Metabase by routing analytics queries through your service mesh. This setup gives teams safe, logged ways to read production data for charts. Metabase turns raw database rows into clear charts for your whole team. Kuma manages the network paths between your apps and those data stores. When you run both tools together, you control how chart queries move across services. You also keep strict network rules around your most sensitive tables. How Kuma and Metabase handle logins a

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.

You pair Kuma and Metabase by routing analytics queries through your service mesh. This setup gives teams safe, logged ways to read production data for charts.

Metabase turns raw database rows into clear charts for your whole team. Kuma manages the network paths between your apps and those data stores. When you run both tools together, you control how chart queries move across services. You also keep strict network rules around your most sensitive tables.

How Kuma and Metabase handle logins and data flow

In a standard setup, Metabase runs as its own service inside a zone. Your databases also sit inside the mesh behind sidecar containers. When an analyst runs a report, the reporting app sends a query out. The local mesh sidecar grabs that outbound traffic right away.

Kuma checks its traffic rules to see if the analytics app can talk there. It uses mutual TLS to check the identity of both workloads. If the rule allows traffic, the query moves across the encrypted mesh path. The database sidecar accepts the request and passes it to the local port.

At that point, the database checks the user login and role. Metabase holds a stored database password to log in and read the tables. The database runs the query and sends the rows back through the mesh. The reporting tool then builds the chart for the user in their browser.

Common failure modes with shared database logins

Many teams set up the network mesh well but leave database logins too broad. Metabase often uses one shared service account for every person on the team. That means fifty analysts might run queries through the exact same database user. When a bad query slows down the database, logs only show the shared account.

You cannot see which person ran the heavy report during an outage. Shared accounts also tend to gain too many read permissions over time. One team needs billing data, so admins grant billing table rights to the account. Soon, every casual chart viewer can query rows with emails and card numbers.

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

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Another common issue happens when mesh traffic rules stay too wide in production. If you allow all services to talk by default, any app can reach data. You should turn on strict mesh rules so only approved workloads can talk. Grant the reporting service access only to read replicas, never the primary writer.

Scoping roles and network paths for analytics

Start by creating a dedicated read replica just for your reporting workloads. Place this replica in its own mesh group with strict traffic permissions. Set up Kuma so only the Metabase service identity can reach that replica port. Block all other apps from sending traffic to your analytics database node.

Next, clean up the database role that your reporting tool uses to log in. Remove broad read rights across the public schema right away. Grant select rights only on the exact tables and views needed for charts. If a table holds phone numbers or national IDs, keep it off limits.

You should also set query timeouts on the database role itself. Analysts will build big joins that scan millions of rows by mistake. A strict thirty-second timeout stops runaway queries from hurting your replica node. Check your mesh traffic metrics each week to spot weird spikes in data transfer.

Add runtime guardrails and masking beside your databases and APIs

Login rules, role grants, and CI checks govern who connects to your stack. Yet any allowed script, engineer, or AI agent still runs commands with the full scope of its role. For workloads on Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes, SSH, or internal HTTP services, hoop.dev sits beside the service as an open-source proxy, a sidecar for your database or API.

Before a query runs, hoop.dev guardrails check the statement against your rules. An AI Analyzer you configure can score intent or hold risky calls for human review. Next, hoop.dev data masking rewrites sensitive fields in responses, and each verdict is logged per listener. Explore the MIT-licensed project on GitHub.

Frequently asked questions

Should Metabase query the primary database through the mesh?

No, you should always route analytics queries to a dedicated read replica. Heavy reporting queries can lock tables and slow down your main app traffic.

Does Kuma replace database users and roles for Metabase?

No, the service mesh only controls and encrypts network traffic between workloads. You still need strict database roles to limit which tables the app can read.

How do we protect emails and card numbers in Metabase charts?

Limit the database role to safe views, or use dynamic data masking. Masking rewrites matched fields like emails and card numbers in query results.

The query runs. The emails stay hidden.