Localhost vs 127.0.0.1 in .env: The Bug That Only Appears on Windows
Same code. Same .env. Works on my Linux box, dies on the Windows server with ECONNREFUSED ::1:3306. Here's what localhost actually does under the hood, why 127.0.0.1 is not always the same thing, and the rules I now follow in every .env file.
Read →