Question

I have launched an EC2 linux instance (a rightscale CentOS v 5.2 i386 image) and want have followed a tutorial (http://www.ardentsoft.com/blog/2009/3/4/lamp-on-ec2-part-6-configuring-apache.html) for configuring PHP and Apache. Now I need to know how to get my PHP files from my dedicated server up to the cloud. I usually use dreamweaver to edit and FTP files to my dedicated server so if I could carry on using that it would be preferable. I have used Putty to login to my instance and have found some tutorials about SSH tunneling with dreamweaver but don't fully understand this.

Once I have done this, I want to know how I can package this server image with all my PHP code and have it ready to go at a moments notice, is this bundling? Can i bundle my configured running image as a new image that I can launch and have ready to go?

Many thanks

Was it helpful?

Solution

Yes, this is bundling. You can either use the AWS Manager provided by Amazon or ElasticFox. Both will do what you need.

Your basic steps are:

  1. Create your server instance on EC2
  2. Upload all code and configure it fully start up and run as you expect.
    1. If you are running a Windows instance, use Remote Desktop
    2. If you are running a Linux instance, use ssh/scp
  3. Get your server fully running as you want it to operate.
  4. Create a bundle. This "archives" your instance into a Bundle. Once complete (this process can take up to an hour, IIRC), you will have a custom EC2 machine that you can fire up. Steps:
    1. Create a "bucket" on Amazon S3 to hold your bundle. You can do this from the Amazon web site or using ElasticFox
    2. Using AWS Manager (ElasticFox will be similar), click on Instance Actions and "Bundle Instance".
    3. You must enter the S3 bucket name (this is typically a lower-case, no space identifier) and your S3 access key.
  5. Lather, rinse, repeat. I had to bundle multiple times to get the startup working as I expected (so expect multiple attempts).

OTHER TIPS

You can use dreamweaver to connect to it as well with an ftp connection.

Install vsftpd: http://www.synergycode.com/knowledgebase/blog/item/ftp-server-on-amazon-ec2

Then just connect using an active connection and point to /var/www/html/ with the user as root and the password you have set.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top