InCo2025's avatar

InCo2025 wrote a reply+100 XP

5mos ago

@jlrdw After some major debugging I could trace it back to my tenantScope which would result in an endless loop causing memory exhaustion. .

 */
public function apply(Builder $builder, Model $model): void
{
    if(auth()->check()){
        $builder->where('tenant_id', auth()->user()->tenant_id);
    }

}
InCo2025's avatar

InCo2025 wrote a reply+100 XP

5mos ago

Thank you for your answer. If futher information would help you, please let me know.

InCo2025's avatar

InCo2025 started a new conversation+100 XP

5mos ago

Hey Guys, I have a vue frontend running via docker and nginx and a laravel 12 application as my backend working as an api and a little admin panel. I'm currently switching from tokens to cookies (which was working fine). I've followed the instructions of the laravel documentation.

Here is the behavior: I can fetch the sanctum cookie and login. Then when I send a request to a route protected by auth:sanctum I get encounter a 500 error without any response. There is no information about it in the log files apart from the request itself showing 500 Get Request. The api shows 500 after that, I need to remove the session entry in the cookies again or use incognito tab to be able to see the api in the browser again.

I've tried a lot of different configurations (using different session_drivers as an example) , but nothing seemed to help. Does anyone know what to do?

Thank you for your help in advance!