MutliTenancy for Cockpit

Dear all,

it would be great if there could be multiple tenants on one Cockpit installation.
Basically I mean that the data is seperated based on the login and the assigned tenant to the logged in user. This should also apply to the API of course.

If this is already possible, please let me know how I can achieve this.


+1 on this suggestion. I created a new user and i was expecting multiple tenants to be supported as in other platforms but sadly is not.

<?php $app->on('cockpit.bootstrap', function() { echo print_r($this->config, true); });

I made a folder inside addons, created a bootstrap.php and i got access to the config variables. I think it can be easy to override the local variables, detect if someone logged in and simple add a prefix for the logged in user to use another storage path.


create a defines.php in the root of the cockpit folder. this file will get always loaded first:

here you can define eg. a custom COCKPIT_ENV_ROOT based on e.g $_SERVER['SERVER_NAME'] to support multiple instances with one cockpit installation

Can i grab the session in there? To make it based on the logged in user?