Since starting an EC2 instance setup can be tricky, and indeed, on the date I write this answer, there is not much support or documentation available, I will post the steps that I followed, which worked for me. Therefore, I hope this will be useful to someone else:
- Start the EC2 instance as described in the AWS documentation. Do not use elastic beanstalk to deploy your php application.
- Start a PuTTY session, it is well described in the AWS documentation.
When the PuTTY session is enabled, install it in the following order: apache server (v 2.4), php55, php55-mcrypt, php55-pdo and mysql55
sudo yum install httpd24 sudo yum install php55 sudo yum install php55-mcrypt sudo yum install php55-pdo sudo yum install mysql55
Verify that your sudo service httpd start server is working properly. If you have successfully installed, you will see "OK", and you will be able to see a sample page in the public DNS.
Add a group to allow "ec2-user" to modify and write files inside var / www / html
sudo groupadd www sudo usermod -a -G www ec2-user
Exit PuTTY and run again (so the changes will be applied) exit
Connect and verify membership
groups
Change write and edit permissions
sudo chown -R root:www /var/www sudo chmod 2775 /var/www find /var/www -type d -exec sudo chmod 2775 {} + find /var/www -type f -exec sudo chmod 0664 {} +
Check your server
echo "<?php phpinfo(); ?>" > /var/www/html/phpinfo.php sudo service httpd restart
visit http: //publicdomain/phpinfo.php . If it works correctly (it should), it will display a page with php information.
All these steps worked well for me after hours of working with php versions that are not compatible with laravel 4.1> =
source share