PHPackages                             contenir/storage - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [File &amp; Storage](/categories/file-storage)
4. /
5. contenir/storage

ActiveLibrary[File &amp; Storage](/categories/file-storage)

contenir/storage
================

Framework-agnostic asset storage for Contenir CMS — local, S3-compatible, and Cloudflare Images adapters with a shared variant pipeline.

v0.3.2(3w ago)0371MITPHPPHP ^8.1 || ^8.2 || ^8.3

Since May 5Pushed 3w agoCompare

[ Source](https://github.com/contenir/storage)[ Packagist](https://packagist.org/packages/contenir/storage)[ RSS](/packages/contenir-storage/feed)WikiDiscussions main Synced 1w ago

READMEChangelogDependencies (8)Versions (9)Used By (1)

contenir/storage
================

[](#contenirstorage)

Framework-agnostic asset storage for [Contenir CMS](https://github.com/contenir).

Provides a unified `StorageInterface` for reading, writing, and listing CMS-managed assets across local filesystem, S3-compatible object stores, and Cloudflare Images, with a shared variant pipeline (responsive image sizes derived from a single source).

Install
-------

[](#install)

```
composer require contenir/storage
```

The package itself only requires `league/flysystem` and `psr/log`. Pull in the optional dependencies for the adapter and features you use:

You needAlso requireLocal image variant generation`gumlet/php-image-resize`S3 adapter`league/flysystem-aws-s3-v3`Cloudflare Images adapter`cloudflare/sdk`Usage
-----

[](#usage)

```
use Contenir\Storage\StorageManager;
use Contenir\Storage\Adapter\LocalFilesystem;
use Contenir\Storage\VariantRegistry;

$variants = new VariantRegistry();
$variants->register('admin-thumb', new Variant(width: 200, height: 200));

$manager = new StorageManager();
$manager->register('default', new LocalFilesystem(
    rootPath: '/var/www/uploads',
    publicUrl: 'https://example.com/uploads',
    variants: $variants,
));

$backend = $manager->get('default');
$url = $backend->url('logos/site.png', variant: 'admin-thumb');

// Convenience for the canonical admin-thumbnail variant. Returns null
// when the profile doesn't declare it or the asset hasn't been
// materialised yet — CMS UIs can call this on any profile and fall back
// to whatever URL they have on hand.
$thumb = $backend->thumbnailUrl('logos/site.png');
```

See `src/Adapter/` for the full set of adapters and `tests/` for end-to-end examples against each.

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance95

Actively maintained with recent releases

Popularity11

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~2 days

Total

8

Last Release

22d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f377cb072a13f76c1b06d272c1f21f41903b3a90d9e1c5c6d928a955fe815441?d=identicon)[peptolab](/maintainers/peptolab)

---

Top Contributors

[![simon-mundy](https://avatars.githubusercontent.com/u/46739456?v=4)](https://github.com/simon-mundy "simon-mundy (7 commits)")

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/contenir-storage/health.svg)

```
[![Health](https://phpackages.com/badges/contenir-storage/health.svg)](https://phpackages.com/packages/contenir-storage)
```

###  Alternatives

[laravel/framework

The Laravel Framework.

34.7k532.1M19.2k](/packages/laravel-framework)[tempest/framework

The PHP framework that gets out of your way.

2.2k31.1k11](/packages/tempest-framework)[league/flysystem-aws-s3-v3

AWS S3 filesystem adapter for Flysystem.

1.7k277.8M952](/packages/league-flysystem-aws-s3-v3)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.4M195](/packages/sulu-sulu)[matomo/matomo

Matomo is the leading Free/Libre open analytics platform

21.6k38.2k](/packages/matomo-matomo)[shopware/platform

The Shopware e-commerce core

3.4k1.5M3](/packages/shopware-platform)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
