Install PHP7 When Using ScotchBox

If you want to update the ScotchBox php version to version 7, you have to follow the steps below:

Open a vagrant ssh session:

vagrant ssh

Update apt:

apt-get update

Install php7:

sudo apt-get update
sudo LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php   
sudo apt-get install -y php7.0
sudo apt-get install -y php7.0-mysql libapache2-mod-php7.0 php7.0-fpm php7.0-json php7.0-xmlrpc php7.0-cgi php7.0-opcache php7.0-zip php7.0-imap php7.0-curl php7.0-xml php7.0-gd

Enable php7:

sudo a2enmod proxy_fcgi setenvif
sudo a2enconf php7.0-fpm

sudo a2dismod php5
sudo a2enmod php7.0
sudo apachectl restart
sudo service apache2 reload