PHPackages                             freezlike/maintenance-bundle - 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. freezlike/maintenance-bundle

ActiveSymfony-bundle

freezlike/maintenance-bundle
============================

A Symfony bundle to manage maintenance mode with notifications.

v1(1y ago)644MITPHPPHP &gt;=8.0CI failing

Since Dec 24Pushed 1y ago2 watchersCompare

[ Source](https://github.com/freezlike/symfony-maintenance-bundle)[ Packagist](https://packagist.org/packages/freezlike/maintenance-bundle)[ RSS](/packages/freezlike-maintenance-bundle/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)DependenciesVersions (3)Used By (0)

Maintenance Bundle
==================

[](#maintenance-bundle)

Introduction
------------

[](#introduction)

The **Maintenance Bundle** is a Symfony bundle for managing maintenance mode in your application. It provides the ability to schedule maintenance, notify users about upcoming maintenance, and allow specific roles to bypass maintenance mode.

Features
--------

[](#features)

- Activate or deactivate maintenance mode.
- Display the next maintenance date.
- Notify users about upcoming maintenance via a global notification.
- Allow specific roles to bypass maintenance mode.

Requirements
------------

[](#requirements)

- PHP 8.0 or higher
- Symfony 6.0 or higher

Installation
------------

[](#installation)

1. Install via Composer:

    ```
    composer require freezlike/maintenance-bundle:dev-main
    ```
2. Enable the bundle in `config/bundles.php`:

    ```
    return [
        FreezLike\MaintenanceBundle\MaintenanceBundle::class => ['all' => true],
    ];
    ```
3. Configure the bundle in `config/packages/maintenance.yaml`:

    ```
    maintenance:
        active: false
        next_maintenance_date: '2024-12-31 12:30'
        allowed_role: 'ROLE_ADMIN'
    ```
4. If you use security bundle enable lazy mode in `config/packages/security.yaml` under the filewall(s) you use:

    ```
    firewalls:
         dev:
             lazy: true
             pattern: ^/(_(profiler|wdt)|css|images|js)/
             security: true
             custom_authenticators:
                 - App\Security\CustomAuthenticator
         main:
             lazy: true
             provider: custom
             custom_authenticators:
                 - App\Security\CustomAuthenticator
    ```
5. Clear the cache:

    ```
    php bin/console cache:clear
    ```

Usage
-----

[](#usage)

### Activating Maintenance Mode

[](#activating-maintenance-mode)

Set the `active` parameter to `true` and configure the next maintenance date:

```
maintenance:
    active: true
    next_maintenance_date: '2024-12-31 12:30'
    allowed_role: 'ROLE_ADMIN'
```

### Displaying Maintenance Notifications

[](#displaying-maintenance-notifications)

To notify users about the next maintenance, use the `next_maintenance_date()` function in your templates:

```
{% if next_maintenance_date() %}

        Next maintenance is scheduled for: {{ next_maintenance_date() }}

{% endif %}
```

### Maintenance Page

[](#maintenance-page)

When maintenance mode is active, users without the specified role will see a maintenance page. The page inherits your application's design and displays a message with the next maintenance date.

### Extending Notifications

[](#extending-notifications)

The notification message can be customized by overriding the `base.html.twig` file or using Twig blocks.

Contribution
------------

[](#contribution)

Contributions are welcome!

1. Fork the repository.
2. Create a feature branch.
3. Submit a pull request.

License
-------

[](#license)

This bundle is open-source and available under the [MIT License](LICENSE).

You are free to use, modify, and distribute this bundle, even for commercial purposes, as long as you include the copyright notice and license terms in any copy or substantial portion of the bundle.

For more details, see the [LICENSE](LICENSE) file.

###  Health Score

30

—

LowBetter than 65% of packages

Maintenance45

Moderate activity, may be stable

Popularity13

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

Unknown

Total

1

Last Release

501d ago

### Community

Maintainers

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

---

Top Contributors

[![freezlike](https://avatars.githubusercontent.com/u/3648460?v=4)](https://github.com/freezlike "freezlike (33 commits)")

---

Tags

maitenancephpsymfonysymfony5symfony6

### Embed Badge

![Health badge](/badges/freezlike-maintenance-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/freezlike-maintenance-bundle/health.svg)](https://phpackages.com/packages/freezlike-maintenance-bundle)
```

PHPackages © 2026

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