502 and 403

Bad gateway to PHP-FPM/proxy and forbidden docroot/security cases.

502 Bad Gateway

Usually nginx/proxy could not reach PHP-FPM or a Node/Python upstream:

  1. Stack tab — are nginx/php-fpm (Native) or the web container (Docker) running?
  2. Is the PHP pin installed? Otherwise fallback + warning on sync
  3. For Node/Python proxy — is the managed dev server alive on the right port?
  4. Web logs / macstack doctor --stack
  5. After changing PHP in Docker, wait for the rebuild

403 Forbidden

Often a wrong docroot or security rules:

  1. Ensure the index file is in the real docroot (Docroot)
  2. Check .macstack/nginx.conf — no accidental deny on /
  3. Bitrix/CMS: is the installer finished; any IP lock in app config?
  4. File permissions under ~/MacFullStack/www/…

After config edits — Reload / Sync vhosts.

Download Pro Teams