One of the best perks for a web developer switching to a Unix based operating system like mac/linux is the relative ease of setting up a environment for web development. Most web servers are linux/unix based and developing on a machine that better mimics a their environment is of great benefit.
Previously on Ubuntu, setting up a solid web server included grabbing multiple packages and a little bit of hand holding to get things right.
However, now that’s changed. Getting a functional web server on Ubuntu not only installed, but up and running now only takes 1 command.
Wait for it…..
Wait for it…..
sudo apt-get install lamp-server^
Yup that’s it.
Follow the prompts, particularly for mySQL and make sure you remember your user/pass (do yourself a favor and make it simple or you’ll regret it).
Once it is done with all the prompt just type:
sudo /etc/init.d/apache2 restart
Now, in your browser go to http://127.0.0.1 or localhost and you should see a page that says, “IT WORKS” which in short means, well… that your web server is functionining.
Now just navigate to your web server root directory using
cd /var/www/
to check out the contents.
BONUS.
Here are a few quick Apache commands for you to chew on:
To start Apache:
sudo /etc/init.d/apache2 start
To stop Apache:
sudo /etc/init.d/apache2 stop
and of course, to restart apache in one command:
sudo /etc/init.d/apache2 restart
Part 2 will cover a quick vhost setup that can simplify your webserver / working environment and drastically increase tidyness and productivity. That will be coming soon.
Posted in Ubuntu, development, linux.
Tagged with apache, mySQL, perl, php, Ubuntu, ubuntu karmic, web development, web server.
By Badams
– December 19, 2009
What is Version Control?
Ever lost a file on you were close to finishing? Maybe the power went out and you had not saved it yet, or the hard-drive failed and your file was corrupted, or you accidentally saved over your working copy? Enter Version Control to save your day!
Think of version control as a file/folder backup system geared towards programmers/designers (although it CAN have wider uses).
There are many types of version control systems out there but I am going to focus on just a few — namely Subversion(SVN) and GIT.
I am by no means an expert or guru on either GIT or SVN but I am going to walk you through the benefits of each then show you how to get started using them.
Getting Started
GIT
GIT actually works better on Mac and Linux at the moment, but don’t let that stop you. There aren’t any issues really on Windows machines.
Lets install GIT.
- Windows — Read this post to get GIT installed and up
- Mac — Easy peasy. Read an install rundown here, or grab this installer
- Linux — Easiest of the bunch.
- Debian folks (Ubuntu included) can just grab this package.
- Ubuntu, grab the Debian package above or from the command line:
apt-get install git-core
- Fedora users check go here or from the command line:
yum install git
SVN
- Windows — Install this or get TortoiseSVN
- Mac — Install a client like Versions , but as of OSx 10.5 you’ve already got SVN!
- Linux — Still easy. Then again, I’m partial.
Part 2: Our First GIT/SVN repositories…
Posted in being wise, development, programming.
Tagged with cvs, git, github, linux, mac, msysgit, subversion, svn, tortoisesvn, version control, versions, windows.
By Badams
– December 18, 2009