tenancy icon indicating copy to clipboard operation
tenancy copied to clipboard

Laravel Spark integration

Open mick340 opened this issue 7 years ago • 14 comments

Hi, is there any support for Laravel Spark? Im using laravel spark for teams so if somebody is going to register a new team i want a tenancy for that team.

So for example if i create a new team called Test, i want a test.mydomain.com tenanct.

I hope this will be added soon or if someone could help me that would be nice.

mick340 avatar Nov 26 '19 10:11 mick340

Hi. Documenting Spark integration is planned, but it's not of high priority at the moment.

The exact thing you're describing sounds like you want to listen to a "team was created" event and do Tenant::new() with the tenant's data and domains.

stancl avatar Nov 26 '19 12:11 stancl

Hi, would it be possible with for example financial support to give this feature a higher priority? ;)

BeniSt avatar Nov 26 '19 13:11 BeniSt

Hi. Documenting Spark integration is planned, but it's not of high priority at the moment.

The exact thing you're describing sounds like you want to listen to a "team was created" event and do Tenant::new() with the tenant's data and domains.

That is what im trying to do, but also de routing isnt working because of the tenancy routes

mick340 avatar Nov 27 '19 21:11 mick340

To mark the routes as tenant routes, apply the 'tenancy' middleware group to Spark routes.

I think this should be somewhat similar to Nova integration: https://tenancy.samuelstancl.me/docs/v2/nova/

stancl avatar Nov 27 '19 21:11 stancl

To mark the routes as tenant routes, apply the 'tenancy' middleware group to Spark routes.

I think this should be somewhat similar to Nova integration: https://tenancy.samuelstancl.me/docs/v2/nova/

Oke thankyou i will give it a try

mick340 avatar Nov 27 '19 21:11 mick340

Hi. Documenting Spark integration is planned, but it's not of high priority at the moment.

The exact thing you're describing sounds like you want to listen to a "team was created" event and do Tenant::new() with the tenant's data and domains.

I guess I have to do this before a team is registered? Because all of the team stuff isn't in the apps DB anymore this will be in the tenant right?

mick340 avatar Nov 27 '19 22:11 mick340

I hope to look into Spark soon. Right now I'm sorry, but I don't know enough about Spark to help with that.

You need to decide what should be in the central database and what should be in the tenant databases. If teams = tenants, then teams should be in the central database.

I recommend reading through this package's docs. They might help with these things.

stancl avatar Nov 27 '19 22:11 stancl

@BeniSt

Hi, would it be possible with for example financial support to give this feature a higher priority? ;)

That would be very much appreciated. Though I don't have a Spark license and I can't promise if I can realistically get to this soon, so I don't want to get donations for a feature that I'm not sure I can make happen. Maybe I could help you integrate this package into a Spark app and then document the process?

stancl avatar Nov 27 '19 22:11 stancl

@BeniSt

Hi, would it be possible with for example financial support to give this feature a higher priority? ;)

That would be very much appreciated. Though I don't have a Spark license and I can't promise if I can realistically get to this soon, so I don't want to get donations for a feature that I'm not sure I can make happen. Maybe I could help you integrate this package into a Spark app and then document the process?

To mark the routes as tenant routes, apply the 'tenancy' middleware group to Spark routes.

I think this should be somewhat similar to Nova integration: https://tenancy.samuelstancl.me/docs/v2/nova/

Sadly for Spark there is no such thing as a config file like Nova has, so can't place the tenancy middleware. Could be cool if we can figure this out together

mick340 avatar Nov 27 '19 22:11 mick340

Isn't there a SparkServiceProvider or something?

stancl avatar Nov 28 '19 16:11 stancl

@stancl I will of course give you access to a new and empty spark installation. It would be fantastic, if you will have a look how to integrate this.

BeniSt avatar Nov 28 '19 16:11 BeniSt

@BeniSt Could you contact me on Telegram or Discord?

stancl avatar Nov 28 '19 16:11 stancl

Decided to not do this. Spark is too old.

stancl avatar Apr 13 '20 00:04 stancl

What's up with spark next?

jetwes avatar Mar 29 '21 07:03 jetwes