PHPackages                             kjos/orchestra - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. kjos/orchestra

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

kjos/orchestra
==============

Orchestra tool for Laravel and other

1.3.4(8mo ago)0570MITPHPPHP &gt;=7.0CI passing

Since Jun 15Pushed 8mo agoCompare

[ Source](https://github.com/jeankoffi543/orchestra)[ Packagist](https://packagist.org/packages/kjos/orchestra)[ RSS](/packages/kjos-orchestra/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (17)Versions (26)Used By (0)

[![Tests](https://github.com/jeankoffi543/orchestra/actions/workflows/tests.yml/badge.svg)](https://github.com/jeankoffi543/orchestra/actions)[![Packagist Version](https://camo.githubusercontent.com/cc62264f535125ae6887aedca65d58ebec6dcd1d3f1dc4e0525bc7e441da4257/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6b6a6f732f6f7263686573747261)](https://camo.githubusercontent.com/cc62264f535125ae6887aedca65d58ebec6dcd1d3f1dc4e0525bc7e441da4257/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6b6a6f732f6f7263686573747261)[![PHP](https://camo.githubusercontent.com/29e76b25f44fd19ba3a88f85f00b3ac7329ffd604075db0fbbeda87f6c794491/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d253545382e302d626c7565)](https://camo.githubusercontent.com/29e76b25f44fd19ba3a88f85f00b3ac7329ffd604075db0fbbeda87f6c794491/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d253545382e302d626c7565)[![License](https://camo.githubusercontent.com/2fe8094062c565b98e702972969e8475dc9f40b2c70b2f6f29971e50bd18ca07/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f6a65616e6b6f6666693534332f6f7263686573747261)](https://camo.githubusercontent.com/2fe8094062c565b98e702972969e8475dc9f40b2c70b2f6f29971e50bd18ca07/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f6a65616e6b6f6666693534332f6f7263686573747261)

🌐 Multilangue | Multilingual
----------------------------

[](#-multilangue--multilingual)

- 🇫🇷 [Version Française](README.fr.md)
- 🇬🇧 [English Version](README.md)

🇬🇧 English
----------

[](#-english)

kjos orchestra
==============

[](#kjos-orchestra)

A powerful multi-tenancy manager for Laravel, with built-in support for domain isolation, database separation, and automated Apache virtual host configuration.

Installation
============

[](#installation)

`composer require kjos/orchestra`

Master tenant installation
--------------------------

[](#master-tenant-installation)

Before beginning you must install the master tanant. We will ask you to configure the `User` wo will use for virtuals hosts creation. When `User` is configure, a shedule task is creating in your crontab table, you can type `crontab -e` to see it. The shedule task will use your `User` with it privileges to automate the creation et configuration of your `virtualhost`. `virtualhosts` are configured in /etc/apache2/sites-available directory.

Concept
=======

[](#concept)

`kjos/orchestra` simplifies the management of multi-tenant applications by providing:

- Independent databases per tenant
- Separate route files, config, and storage per tenant
- Automatic setup of Apache virtual hosts
- Easy tenant lifecycle management via Artisan commands

It’s ideal for SaaS platforms or systems requiring strict tenant isolation.

Getting Started
===============

[](#getting-started)

Master Tenant Setup
-------------------

[](#master-tenant-setup)

Before adding tenants, you must install and configure the master tenant.

What happens during setup?
--------------------------

[](#what-happens-during-setup)

You’ll configure a system User that will be used to manage Apache virtual hosts.

A scheduled task will be added to your crontab to automate virtual host creation.

Apache virtual hosts are stored in: /etc/apache2/sites-available/

Installation Steps
------------------

[](#installation-steps)

1. Create &amp; configure the master tenant
2. Publish the config file:

```
php artisan vendor:publish --tag=orchestra-config

```

3. Create the database for the master tenant
4. Add the tenant to the .tenants file at your project root
5. Create the site/ directory, which will contain subfolders for each tenant
6. Link each tenant's /public directory to your Laravel public root
7. Configure the virtual host:

- Symlink: /var/www/html/{tenant-domain} → project/site/{tenant-name}
- Apache config: /etc/apache2/sites-available/{tenant-domain}.conf
- Log file: /var/log/apache2/{tenant-domain}.log

8. Enable the virtual host:

```
sudo a2ensite {tenant-domain}.conf
sudo systemctl reload apache2

```

9. Register the service provider in config/app.php:

```
App\Providers\TenantServiceProvider::class,

```

The `TenantServiceProvider` is the central kernel that initializes and resolves tenant-specific context and configuration.

Artisan Commands
----------------

[](#artisan-commands)

### Install Master Tenant

[](#install-master-tenant)

`php artisan orchestra:install the_master_tenant_name --domain=master_tenant_domain --driver=[mysql|pgsql]`

### ❌ Uninstall Master Tenant

[](#-uninstall-master-tenant)

`php artisan orchestra:uninstall the_master_tenant_name --driver=[mysql|pgsql]`

### ➕ Create a New Tenant

[](#-create-a-new-tenant)

`php artisan orchestra:create the_tenant_name --domain=the_tenant_domain --driver=[mysql|pgsql] --migrate`

### ➖ Delete a Tenant

[](#-delete-a-tenant)

`php artisan orchestra:delete the_tenant_name --driver=[mysql|pgsql]`

### 🧾 Available Options

[](#-available-options)

OptionDescription`--domain`The domain of the tenant`--driver`Database driver `pgsql` or `mysql``--migrate`Either migrate the fresh tenant database or not|

Laravel natif command
=====================

[](#laravel-natif-command)

### ➖ Migrate or seed a specific tenant

[](#-migrate-or-seed-a-specific-tenant)

`php artisan migrate --tenant=tenant_name``php artisan db:seed --class=ExempleSeeder --tenant=tenant_name`

### ➖ Migrate or seed a specific all tenants

[](#-migrate-or-seed-a-specific-all-tenants)

`php artisan migrate --tenant``php artisan db:seed --class=ExempleSeeder --tenant`

### Additional Features

[](#additional-features)

Each tenant has its own:

- `routes` (API, web, console)
- `database`
- `storage` &amp; `cache`
- `config` context

Crontab automation for managing virtual hosts

Support for Laravel testing with tenant isolation

Dynamic tenant discovery via `.tenants` file

.

📁 Directory Structure
=====================

[](#-directory-structure)

```
project-root/
├── site/
│   ├── master/
│   │   └── routes/
│   └── tenant-a/
│   |   └── routes/
|   |__ tenant-b/
|       |__routes/
|
├── .tenants
├── config/orchestra.php
├── app/Providers/TenantServiceProvider.php

```

👤 Author
========

[](#-author)

Maintained by [Jean Koffi](https://www.linkedin.com/in/konan-kan-jean-sylvain-koffi-39970399/)

📄 License
=========

[](#-license)

MIT © kjos/orchestra

🤝 Call for contributions
========================

[](#-call-for-contributions)

This project is open to contributions! Are you a developer, passionate about Laravel, or interested in multi-tenant architecture?

- Fork the project
- Create a branch (koor/my-feature)
- Make a PR 🧪

There are many other command for additionally configuration.

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance59

Moderate activity, may be stable

Popularity13

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity42

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 ~6 days

Total

8

Last Release

265d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/3d8b4bf689202fe6d45f906d4c2b90e7bae704df82aac00e1df5f16e5dfd7a34?d=identicon)[jeankoffi543](/maintainers/jeankoffi543)

---

Top Contributors

[![jeankoffi543](https://avatars.githubusercontent.com/u/26505861?v=4)](https://github.com/jeankoffi543 "jeankoffi543 (18 commits)")

###  Code Quality

TestsPest

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/kjos-orchestra/health.svg)

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

###  Alternatives

[barryvdh/laravel-ide-helper

Laravel IDE Helper, generates correct PHPDocs for all Facade classes, to improve auto-completion.

14.9k123.0M687](/packages/barryvdh-laravel-ide-helper)[orchestra/canvas

Code Generators for Laravel Applications and Packages

21017.2M158](/packages/orchestra-canvas)[fumeapp/modeltyper

Generate TypeScript interfaces from Laravel Models

196277.9k](/packages/fumeapp-modeltyper)[zonneplan/laravel-module-loader

Module loader for Laravel

24118.4k](/packages/zonneplan-laravel-module-loader)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)[bjuppa/laravel-blog

Add blog functionality to your Laravel project

483.3k2](/packages/bjuppa-laravel-blog)

PHPackages © 2026

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