Install devenv with Ubuntu + Apache + MySQL
Create a new virtual machine and mount your Ubuntu ISO as CDROM drive. Startup the new virtual machine and install Ubuntu with default options.
After Ubuntu installation is complete be sure to add the guest additions to your system (keep your original configuration when asked):
$>apt-get install virtualbox-guest-x11
Ubuntu windows appearing slow? See this url: http://askubuntu.com/questions/207813/why-does-an-ubuntu-12-10-guest-in-virtualbox-run-very-very-slowly/214968#214968
Upgrade and update your system to make sure you have the latest and the greatest software:
$>apt-get update $>apt-get upgrade
Mandatory components for your development environment
$>apt-get install apache2 $>apt-get install mysql-server libapache2-mod-auth-mysql php5-mysql # Enter root password and press OK (twice) # Install MySQL system tables: $>mysql_install_db # Secure your MySQL installation $>/usr/bin/mysql_secure_installation # Enter the root password choosen above # Choose n (already have a password) # Enter four times (everything default) $>apt-get install php5 php5-xdebug libapache2-mod-php5 php5-mcrypt php5-cli php5-curl php5-gd # Install your favorite editor for quick edits.... $>apt-get install vim
Optional (but useful tools)
WebMin server administration
apt-get install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl apt-show-versions python wget http://prdownloads.sourceforge.net/webadmin/webmin_1.610_all.deb dpkg --install webmin_1.610_all.deb
When you want to mount an external CIFS filesystem (for example your NAS) install the CIFS utility package.
$>apt-get install cifs-utils
Mount a cifs remote file system:
$>mkdir /mnt/share $>mount.cifs //SERVER/share /mnt/share -o user=USER,uid=1000,gid=1000 # Enter your password
# Install netbeans $>apt-get install netbeans # Install chromium-browser Install chrome browser $>apt-get install chromium-browser # Install the Gimp $>sudo apt-get install gimp # Install VIM $>sudo apt-get install vim
Setup WordPress installatie
For pretty URL’s to work make sure the rewrite module is enabled in Apache. You can do this with the WebMin tool; in Webmin goto “Servers”, “Apache Webserver”, select the “Global configuration” tab, select “Configure Apache modules”, check the “Rewrite” module.
Changes take effect immediately.
$>cd /var/www/ $>mkdir demo $>cd demo $>wget http://wordpress.org/latest.tar.gz $>tar -xzvf latest.tar.gz $>mv wordpress www $>rm latest.tar.gz $>cd /var/www $>chown -R www-data:www-data .
Setup the MySQL database
$>mysql -uroot -pXXXXXXX
mysql>create database wp_demo; mysql>create user 'wp_demo'@'localhost' IDENTIFIED BY 'XXXXXXXXXX'; mysql> grant create,drop,select,insert,update,delete on wp_demo.* to 'wp_demo'@'localhost';