Search code examples
amazon-web-servicesamazon-ec2amazon-s3lamp

Setting up LAMP Web Server on AWS EC2 t1 Micro


I'm sorry for being dumb, but I am really stuck for few days. This is my first time using AWS. I have successfully installed LAMP web server under t1.micro on my customer's AWS account http://54.72.132.215/ following this tutorial . But I don't know what to do next after the installation. My goal is:

  1. Setup a Domain

  2. Run a Prestashop.

I hope you can guide me to the right path, I am totally lost. Thanks.


Solution

  • You need to register a domain with someone, this is outside of Amazon. Just google domain name registrars:

    https://www.google.com/webhp?sourceid=chrome-instant&ion=1&espv=2&ie=UTF-8#q=domain%20name%20registrar

    Then you'll need to point your domain to your Amazon EC2 instance. I would suggest using Route 53 to do this, another Amazon AWS service that makes it easier to setup and control your domains:

    http://aws.amazon.com/route53/

    Once you have that setup, visiting your name domain should show the default apache It works! page, if you've correctly setup your LAMP server. It'll look something like these:

    https://www.google.co.uk/search?q=default+apache+web+page&espv=2&source=lnms&tbm=isch&sa=X&ei=yRfWU_v8OeHe7Abp1ICICw&ved=0CAYQ_AUoAQ&biw=1457&bih=881#imgdii=_

    You'll want to add a new vhost for your new PrestaShop site, this will allow you to setup a specific set of files to serve for your new URL, and means you can add other sites to the server later on. Just a quick google shows multiple tutorials on doing this, here's one of them:

    http://calebogden.com/multiple-websites-amazon-ec2-linux-virtual-hosts/

    Then follow the tutorial in the PrestaShop documentation about installing PrestaShop via the command line:

    http://doc.prestashop.com/display/PS16/Installing+PrestaShop+using+the+command-line+script

    Now I'm guessing that all those steps in one go is a little overwhelming, so I would suggest you break this task down into chunks and work on them one at a time, and post a few different questions on StackOverflow and probably ServerFault: https://serverfault.com/, as that is better suited to setting up servers.

    To summarise you need to:

    • register a domain name and point it to your EC2 server, you should see the default apache page
    • create a new vhost to server web pages for your new domain
    • follow the guide on PrestaShop about installing the software

    Treat each of those a separate task. This question covers lots of topics in one very general idea, the full answer to your problem wouldn't really fit in a single post.

    ServerFault will probably have a lot of your answers already, regarding setting up domains and vhosts at least.