Handling multiple php version with Nginx in Mamp 4.x

Viewed 270

I know we can handle different request using nginx by routing them to the wanted php version (see eg. here).

The status :

  • I changed my web server to Nginx in MAMP settings
  • I'm currently served at http://localhost:7888/, successfully

What I need to configure is :

  • serve the app1 using php5.30
  • serve another app2 using php7.1

What I did :

  • I added /Applications/MAMP/conf/nginx/sites-available/app1 and /Applications/MAMP/conf/nginx/sites-available/app2 according to the eg. setup
  • I restarted MAMP (so nginx)

I desperately googled solutions but didn't found working solution, does anyone here can help to have such config? Thank you in advance.

0 Answers
Related