Search code examples
phpphpstorm

phpStorm problems with php-cgi


So I recently change to ubuntu and I am trying to setup my environment again and I manage to install LAMP and phpmyadmin and phpstorm.

But what I can't mange to do is to run the php script from phpStorm when I try to run the program the page gives me a "502 Bad gateway" error and when I go back on phpStorm it tells me that php-cgi was not found.

I have tried to fix the problem but couldn't find any solid answer and I am so confused right now enter image description here

Also I have successfully added the php interpreter and the xDebug

enter image description here


Solution

  • on linux ubuntu

    For PHP5: sudo apt-get install php5-cgi

    For PHP7: sudo apt-get install php7.0-cgi