Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Csrf token issue with scaling

I have scaled my application to 3 different servers that use common mysql and redis service. Than I have set session and cache driver to my redis (they are working fine). But I still get token mismatch error. Did anyone solve this problem without turning off CSRF protection? I`m using Docker by the way.

like image 788
Rostyslav Avatar asked Jan 30 '26 20:01

Rostyslav


1 Answers

php artisan cache:clear helped. Maybe this is required in all cases, when you change some important settings in .env file

like image 95
Rostyslav Avatar answered Feb 01 '26 09:02

Rostyslav



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!