I need to figure out why I'm getting a 504 error when trying to connect to the dev server in my Lumen app. The problem started after upgrading to a new computer with MacOS Mojave 10.14.
I'm using php7.3, MySQL and Homestead as the DB, React.js for the front end. The app uses microservices that are all attached to a backend API gateway.
I'm at a loss and I think I just need some perspective on why the error is occurring. If someone could try to walk me through it as simple as possible it would help a lot.
My assumption is that it has to do with my .env
config.
I've tried
- Reinstalling PHP (currently using php7.3 installed by homebrew)
- Using different MySQL database
- Starting server directly from Homestead (currently Ubuntu 14 VM with virtualbox)
- Re-installing apache2 server (Mojave problem - may not be related)
- Changing
.env
config variables - Restarting/changing DNS server
- Updating
/etc/hosts
file - Increasing gateway timeout in
php.ini
- Turning it off and turning it on...
My .env
file looks like this:
APP_NAME=Lumen
APP_ENV=local
APP_KEY=tHd56UgN634EWSDeRYyy5634REr35T67
APP_DEBUG=true
APP_URL=http://localhost
APP_TIMEZONE=UTC
LOG_CHANNEL=stack
LOG_SLACK_WEBHOOK_URL=
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=mms
DB_USERNAME=aaron
DB_PASSWORD=mangobyte
CACHE_DRIVER=file
QUEUE_CONNECTION=sync
X_MMS_SERVICE_KEYS=iUiWsTfI63ODGAHtqb1Guf05IQcGe3mI
API_PREFIX=v1/
When I start the dev servers for both the API and React, I am able to reach the Login page with a [200]
code status, but when I log in with the Admin credentials (seeded into Homestead DB using Faker), I get a [504]
status.
From the Lumen .log file:
local.ERROR: GuzzleHttp\Exception\ConnectException: cURL error 6: Could not resolve host: v1 (see http://curl.haxx.se/libcurl/c/libcurl-errors.html) in /Users/aaronalt/mango/mms/mms_gateway_back_source/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php:185
I'm curious if it's not communicating with the database in order to receive or verify the login credentials?
Thanks very much!