Vagrant configuration for easier Wordpress development for both creating a website and/or developing a Wordpress Theme.
This Vagrant configuration will do the following:
- Download the Ubuntu 14.05 Vagrant box, if needed (ubuntu/trusty64)
- Apply all patches to the OS and install a few useful utilities
- Install all Wordpress related dependencies
- Apache
- MySQL
- PHP
- Setup links to themes and media folders for wordpress content
- Vagrant
- Virtual Box with Guest Additions installed
- Internet connection
-
Clone this repo into unique folder
git clone https://github.com/srctips/vagrant-wordpress.git my-wp-project
-
Review the files in the setup folder.
- Remember to sync up any changes between the other files -- for example any database connection updates.
-
Start Vagrant
vagrant up
By default, Vagrant setups the /vagrant folder on the guest OS within the virtual machine. The /vagrant folder maps to the source directory containing the Vagrantfile on the host machine.
The /vagrant/media maps to the uploads folder in Wordpress. Any images here should appear on both the host machine.
The /vagrant/themes maps to the themes folder in Wordpress. Any new themes installed via Wordpress will be reflected here and any new folders created here from scratch will appear in Wordpress.
The /vagrant/.gitignore file manages what files are excluded from version control within Git. Currently, media and default Wordpress themes.