Download the PHP package dazza-dev/hyn-multi-tenant without Composer

On this page you can find all versions of the php package dazza-dev/hyn-multi-tenant. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package hyn-multi-tenant

dazza-dev/hyn-multi-tenant

PHP

Run multiple websites from a single Laravel installation, each with one or more hostnames, keeping their data, assets and behaviour separated.


Which version do you need?

Your Laravel version What to use
12 and 13 dazza-dev/hyn-multi-tenant — this package
11 The 1.x line, in maintenance: security and isolation fixes only
9 and 10 The 0.x line, which continues hyn/multi-tenant 5.9

Every line is on Packagist under the same name:

About this repository

A maintained fork of hyn/multi-tenant by Daniël Klabbers. The design and practically all of the code are his and the original contributors'.

The original has received no commits since August 2023 and does not support Laravel 11. Rather than migrate away, we picked up its maintenance. This is the same code, the same Hyn\Tenancy\ namespace and the same API.

If the original project becomes active again we will gladly contribute these changes back.

Features

Tenant separation modes:

Requirements

Installation

Coming from hyn/multi-tenant, read UPGRADE.md first. The namespace does not change.

The service providers are registered through package auto discovery. To opt out and register them yourself, add dazza-dev/hyn-multi-tenant to extra.laravel.dont-discover and register:

Configuration

Adjust config/tenancy.php and config/webserver.php to taste. Make sure the system connection is configured in database.php; the default connection is used unless you override the system connection name.

Documentation

The original documentation applies to everything not listed as changed in UPGRADE.md.

Contributing, and what the test suite needs: CONTRIBUTING.md.

Testing

The suite creates and drops real databases and database users, so it needs a disposable environment. One matching CI is included:

Target another engine or separation mode:

Build against another PHP version with PHP_VERSION=8.4 docker compose build php. The suite runs on 8.2, 8.3 and 8.4.

Running the suite drops tenant and system databases. Never point it at anything you care about.

Credits

To support the original author's work, the original project has an Open Collective.

License

MIT. Original copyright by Daniël Klabbers — see license.md.


All versions of hyn-multi-tenant with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
ramsey/uuid Version ^4.0
laravel/framework Version ^12.0|^13.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package dazza-dev/hyn-multi-tenant contains the following files

Loading the files please wait ...