title: php -v shows cgi-fcgi
body: <p>I was following instructions to install get to clone a repository and then all of the sudden I started getting "bin/magento must be run as a CLI application" error.  </p>
  
  <p>When I did php -v, it shows:</p>
  
  <pre><code>ea-php-cli Copyright 2016 cPanel, Inc.
  PHP 7.0.17 (cgi-fcgi) (built: Apr  5 2017 23:22:19)
  Copyright (c) 1997-2017 The PHP Group
  Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies
  with Zend OPcache v7.0.17, Copyright (c) 1999-2017, by Zend Technologies
  </code></pre>
  
  <p>I've sincerely searched for hours to change this back to show (cli), but so far no luck.  </p>
  
  <p>I've reinstalled ea-php-cli via yum but nothing has changed.  </p>
  
  <p>When I stopped and restarted the httpd, I get a bunch of errors like this one:</p>
  
  <blockquote>
    <p>[alias:warn] [pid 31484] AH00671: The ScriptAlias directive in
    /etc/apache2/conf/httpd.conf at line 645 will probably never match
    because it overlaps an earlier ScriptAlias.</p>
  </blockquote>
  
  <p>Does anyone know the command to change the php mode to cli mode rather than cgi-fcgi mode?  If not, do I need to uninstall and reinstall php?</p>
  
  <p><strong>Update</strong></p>
  
  <p>so after some research I realized that it has to do with the Server API where it's set up as FPM/FAstCGI rather than Apache 2.0 Handler.  I will have to research this and then find out how to switch the server API back to Apache Handler...  I'm running Centos 6.9 so if anyone has an easy solution, I'd greatly appreciate your input.  </p>
  
  <p><strong>More Update</strong></p>
  
  <p>The only thing I can think of that may have affected the Server API to switch is a few of the patches I have made.  Here's a list of all the patches and changes made to the server today:</p>
  
  <pre><code>Apr 15 12:47:02 Installed: kernel-2.6.32-696.1.1.el6.x86_64
  Apr 15 13:14:02 Installed: 1:perl-Error-0.17015-4.el6.noarch
  Apr 15 13:14:02 Installed: perl-Git-1.7.1-8.el6.noarch
  Apr 15 13:14:03 Installed: git-1.7.1-8.el6.x86_64
  Apr 15 19:21:49 Erased: epel-release
  Apr 15 20:33:45 Installed: ea-php-cli-0.2.0-1.1.1.cpanel.x86_64
  Apr 15 21:00:58 Installed: ea-php-cli-0.2.0-1.1.1.cpanel.x86_64
  Apr 15 22:32:44 Installed: ea-php-cli-0.2.0-1.1.1.cpanel.x86_64
  </code></pre>