2

I'm running into a problem using sail share with a Laravel 9.x application using Jetstream + Inertia and Sanctum.

I'm able to load my login screen at the XXXXXX.laravel-sail.site/login URL. However, I'm not able to actually login to the application.

I can see the login form post in Expose dashboard, but there is either never a response, or a 419 Page Expired error occurs (depending on which settings I'm trying, more on that below).

My local site APP_URL is set to http://localhost. The information generated by Expose is:

I'm using the Public HTTP URL to access the login. The Public HTTPS URL generates ERR_CONNECTION_REFUSED.

Here is what I have tried:

  • Set SANCTUM_STATEFUL_DOMAINS and SESSION_DOMAIN to the Public URL in .env (This produces the 419 error). I also tried localhost but never received the POST response at login. Also tried with and without the port on SANCTUM_STATEFUL_DOMAINS.
  • Changed SESSION_DRIVER from database to cookie (same 419 error).
  • Changed 'supports_credentials' to true in config/cors.php.
  • Uncommented \Laravel\Sanctum\Http\Middleware\EnsureFrontendRequestsAreStateful::class in Kernel.php
  • Set $proxies to protected $proxies = '*'; in TrustProxies.php

Does anyone know what I'm missing?

Thanks,

Tim

Tim Gieseking
  • 161
  • 2
  • 10

0 Answers0