Setting up a quick ubuntu Web Development environment

I found myself setting up yet another web dev box. This time I decided to document the process to save myself the the constant Googling when I have to repeat this task.

Please note that the idea of this is to get a dev server up and running as quick as possible. I'm not advocating the use of the server in production.

Step 1: Installing the latest LTS version of Ubuntu

Start of by installing the latest LTS version of Ubuntu.

When installing select ssh and lamp from the setup options (if you skip this you can use the tasksel command to repeat this step), configure as required normally yes to everything will be fine for a dev server.

Step 2: Set the IP address

Once the OS has installed, the first thing to do is to change the IP to a manual address.

From here you need to go into edit mode (i).

You should have something that looks like the following:

You need to change the dhcp to static and add the below (Use what ever subnet and address you like):

When done hit esc to exit and then :w! to save.

After this restart the network service

Step 3: FTP service

Next we need to add an ftp service.

Next we need to make some changes to the vsftpd.conf file

Next change

to NO

and uncomment

This will remove anonymous access and make it so that local users can ftp in and save files.

Finally restart the ftp service

The last thing to is to make a user for the FTP and set up the appropriate permissions for /var/www

This will create a user called ftpman, set their home folder to var/www and put them in the apache www-data group

This will change the owner ship of the www directory and it's contents to the www-data group.

This will give the www-data group read and wright access.

And that is pretty much that you should up and running and coding away...