I am kind of trying to transfer my website to an Amazon EC2 instance. I have set up everything and now when I open my website instead of seeing the website I just get to see the source code.
Is there anything I did wrong in the setup process ?
I am kind of trying to transfer my website to an Amazon EC2 instance. I have set up everything and now when I open my website instead of seeing the website I just get to see the source code.
Is there anything I did wrong in the setup process ?
You can't run PHP code from S3 at all -- it's just a storage service and a web server, it doesn't include a PHP application server. As the other answer states, you can set up an instance in EC2 and run a web application there, but EC2 and S3 are two different services.
If you want to run php of Amazon EC2, you must have to follow this steps
Configuring PHP
First, the basics for PHP:
sudo yum install php-mysql php php-xml php-mcrypt php-mbstring php-cli mysql httpd
Press y
for each of the prompts that shows up. Note that you’re logged in as ec2-user
, so you need to sudo all of these commands.
You should now be able to create and run a PHP test file. Next, let’s get MySQL up and running.
Want more details read this article : Getting PHP and MySQL running on Amazon