Chevereto 4.4

Chevereto goes multitenant

I started Chevereto to democratize image hosting. To move away from a world where media is centralized and controlled by a few Big Brother platforms. My purpose was to empower individuals and organizations with self-hosted software, giving them the freedom to run their own services and helping grow a diverse ecosystem of media-hosting providers.

Chevereto is well known among self-hosters, but outside that circle it doesn’t even exists. This visibility gap limits my vision of decentralization and prevents the software from reaching a wider audience.

This post explains how Chevereto’s multitenant system design works and how Chevereto evolved from a traditional self-hosted application into a modern platform that supports multiple isolated tenants.

# Road to multitenancy

Chevereto has been technically "multi-tenant ready" since Chevereto v4.0.0 (Macanudo) thanks to its ENV-driven configuration. But turning that into something suitable for real-world consumer use required significant work. Over the following two years, I expanded the number of environment variables, introduced new limits and toggles, improved overall safety, and delivered a major performance boost.

Beyond data isolation, the system needed fine-grained controls for provisioning and resource governance, such as maximum users, minimum storage providers, and other related limits. Today, every consumable resource can be shaped to match the constraints of your infrastructure.

Final milestone arrived with Chevereto v4.4, which introduced official multitenancy support through a context resolver and a full tenant management layer. Sysadmins can now provision, manage, and automate tenants through the Tenants CLI and/or Tenants API, completing the transition to a multitenant platform.

# Multitenant system

Chevereto does multitenancy by using a shared database with per-tenant table prefixes. Application instances are portable, with a storage-less design, meant that each tenant freely configure storage at application layer. For deployments that require stricter boundaries, Chevereto supports using a separate database per tenant.

This provides a range of isolation options:

  • Shared database with table prefixes (fastest, cheapest, simplest)
  • Separate databases per tenant (maximum isolation and scalability)
  • Hybrid setups (mix-and-match approaches per tenant or per plan)

The multitenant resolver loads the context for each request. It determines which tenant is being accessed, and applies the right service targets. The resolver runs in memory using Redis, which allows it to perform these operations quickly at runtime.

Under the hood, provisioning a tenant creates its table set, enforces limits, prepares its configuration, and registers the tenant in the system. The resolver then takes care of routing all traffic to the appropriate tenant environment.

# Chevereto-Powered Clouds

The introduction of multitenancy unlocks the ability to offer Chevereto as a hosted service at scale. Simple to deploy, simple to manage, and dramatically more cost-efficient than ever before. With the updated license agreement explicitly permitting commercial use, there has never been a better moment to launch hosted Chevereto services.

We are opening the ecosystem to all providers. This shift means we can now distribute Chevereto powered platforms directly to end-users, enabling them to concentrate on content creation without the burden of technical administration. Service providers, in turn, can construct their entire business model on top of our proven, SaaS-native platform.

While Chevereto Cloud currently leads the way, the foundation is laid for new players to enter the market. A broad provider ecosystem is vital and it ensures competitive alternatives and prevents the kind of monopolistic control that could negatively impact users.

# A broader vision

Multitenancy allows Chevereto to grow beyond individual installations and become the platform behind a diverse ecosystem of hosted media services. Anyone can build new projects, commercial offerings, private hubs, and specialized communities on top of a single Chevereto installation.

This update brings me closer to the original vision of decentralization and user owned media. Instead of a world controlled by a few centralized platforms, Chevereto aims to enable thousands of independent providers who each serve their own audiences on their own terms.

If you're curious to explore it, check the full multitenancy documentation.

# What's next

With multitenancy in place, the next frontier is a comprehensive 1:1 API that transforms Chevereto into a true headless CMS. This will empower developers to build custom galleries, uploaders, and integrations while leveraging Chevereto's proven engine. Combined with our multitenant architecture, this opens the door for even more innovative use cases and provider-specific customizations.

Rodolfo blogging since 2012.