summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Vagrantfile96
-rw-r--r--doc/vagrant.markdown64
2 files changed, 12 insertions, 148 deletions
diff --git a/Vagrantfile b/Vagrantfile
index 63846c3d..7db068e4 100644
--- a/Vagrantfile
+++ b/Vagrantfile
@@ -1,54 +1,16 @@
-$debian_script = <<SCRIPT
-apt-get update
-apt-get install -y apache2 php5 php5-gd php5-curl php5-sqlite php5-xdebug php5-ldap
-apt-get clean -y
+$script = <<SCRIPT
+apt-get install -y apache2 php5 php5-sqlite php5-mysql php5-pgsql php5-gd curl unzip && \
+apt-get clean && \
+echo "ServerName localhost" >> /etc/apache2/apache2.conf && \
+sed -ri 's/AllowOverride None/AllowOverride All/g' /etc/apache2/apache2.conf && \
+a2enmod rewrite
-sudo sed -ri 's/AllowOverride None/AllowOverride All/g' /etc/apache2/apache2.conf
-
-if [ -f /etc/apache2/sites-enabled/000-default ]; then
- sudo sed -ri 's/AllowOverride None/AllowOverride All/g' /etc/apache2/sites-enabled/000-default
-fi
-
-sudo a2enmod rewrite
service apache2 restart
rm -f /var/www/html/index.html
date > /etc/vagrant_provisioned_at
-wget -q https://getcomposer.org/composer.phar
-chmod +x composer.phar
-sudo mv composer.phar /usr/local/bin/composer
-
-wget -q https://phar.phpunit.de/phpunit.phar
-chmod +x phpunit.phar
-sudo mv phpunit.phar /usr/local/bin/phpunit
-
-SCRIPT
-
-$centos_script = <<SCRIPT
-sudo yum update -y
-sudo yum install -y httpd php php-cli php-gd php-ldap php-mbstring php-mysql php-pdo php-pgsql php-xml wget
-
-sudo sed -ri 's/AllowOverride None/AllowOverride All/g' /etc/httpd/conf/httpd.conf
-
-if [ -x /usr/bin/systemctl ]; then
- sudo systemctl restart httpd
- sudo systemctl enable httpd
- sudo chcon -R -t httpd_sys_content_rw_t /var/www/html/data
- sudo setsebool -P httpd_can_network_connect=1
-else
- sudo service httpd restart
- sudo chkconfig httpd on
-fi
-
-rm -f /var/www/html/index.html
-date > /etc/vagrant_provisioned_at
-
-wget -q https://getcomposer.org/composer.phar
-chmod +x composer.phar
-sudo mv composer.phar /usr/local/bin/composer
-
wget -q https://phar.phpunit.de/phpunit.phar
chmod +x phpunit.phar
sudo mv phpunit.phar /usr/local/bin/phpunit
@@ -59,52 +21,8 @@ Vagrant.configure("2") do |config|
config.vm.define "ubuntu" do |m|
m.vm.box = "ubuntu/trusty64"
- m.vm.provision "shell", inline: $debian_script
+ m.vm.provision "shell", inline: $script
m.vm.synced_folder ".", "/var/www/html", owner: "www-data", group: "www-data"
m.vm.network :forwarded_port, guest: 80, host: 8001
end
-
- config.vm.define "debian8" do |m|
- m.vm.box = "debian/jessie64"
- m.vm.provision "shell", inline: $debian_script
- m.vm.synced_folder ".", "/var/www/html", owner: "www-data", group: "www-data"
- m.vm.network :forwarded_port, guest: 80, host: 8002
- end
-
- config.vm.define "debian7" do |m|
- m.vm.box = "debian/wheezy64"
- m.vm.provision "shell", inline: $debian_script
- m.vm.synced_folder ".", "/var/www", owner: "www-data", group: "www-data"
- m.vm.network :forwarded_port, guest: 80, host: 8003
- end
-
- config.vm.define "debian6" do |m|
- m.vm.box = "bento/debian-6.0.10"
- m.vm.provision "shell", inline: $debian_script
- m.vm.synced_folder ".", "/var/www", owner: "www-data", group: "www-data"
- m.vm.network :forwarded_port, guest: 80, host: 8004
- end
-
- config.vm.define "centos7" do |m|
- m.vm.box = "centos/7"
- m.vm.provision "shell", inline: $centos_script
- m.vm.synced_folder ".", "/var/www/html", owner: "apache", group: "apache", type: "rsync",
- rsync__exclude: ".git/", rsync__auto: true
- m.vm.network :forwarded_port, guest: 80, host: 8005
- end
-
- config.vm.define "centos6" do |m|
- m.vm.box = "bento/centos-6.7"
- m.vm.provision "shell", inline: $centos_script
- m.vm.synced_folder ".", "/var/www/html", owner: "apache", group: "apache", type: "rsync",
- rsync__exclude: ".git/", rsync__auto: true
- m.vm.network :forwarded_port, guest: 80, host: 8006
- end
-
- config.vm.define "freebsd10" do |m|
- m.vm.box = "freebsd/FreeBSD-10.2-STABLE"
- m.vm.base_mac = "080027D14C66"
- m.ssh.shell = "sh"
- m.vm.network :forwarded_port, guest: 80, host: 8007
- end
end
diff --git a/doc/vagrant.markdown b/doc/vagrant.markdown
index d11bca84..864f37b8 100644
--- a/doc/vagrant.markdown
+++ b/doc/vagrant.markdown
@@ -1,64 +1,10 @@
Run Kanboard with Vagrant
=========================
-Vagrant is used to test Kanboard in different environments.
+You can try Kanboard with Vagrant very easily:
-Several configurations are available:
+- Clone the project from the git repository
+- Run `vagrant up`
+- You can access to the application by using the URL `http://localhost:8001/`
-- Ubuntu 14.04 LTS
-- Debian 8
-- Debian 7
-- Debian 6
-- Centos 7
-- Centos 6.7
-- Freebsd 10
-
-The installation process is not fully automated for all VM, manual configuration can be required.
-
-To use those configurations, you have to install the **last version of Virtualbox and Vagrant**.
-
-Standard boxes can be downloaded from Vagrant:
-
-```bash
-vagrant box add ubuntu/trusty64
-vagrant box add debian/jessie64
-vagrant box add debian/wheezy64
-vagrant box add bento/debian-6.0.10
-vagrant box add centos/7
-vagrant box add bento/centos-6.7
-vagrant box add freebsd/FreeBSD-10.2-STABLE
-```
-
-### Example with Ubuntu and Sqlite
-
-If you want to test Kanboard on Ubuntu with Sqlite:
-
-```bash
-vagrant up sqlite
-```
-
-The current directory is synced to the Apache document root.
-
-Composer dependencies have to be there, so if you didn't run `composer install` on your host machine you can also do it on the guest machine.
-
-Each box has its own TCP port:
-
-- ubuntu: http://localhost:8001/
-- debian8: http://localhost:8002/
-- debian7: http://localhost:8003/
-- debian6: http://localhost:8004/
-- centos7: http://localhost:8005/
-- centos6: http://localhost:8006/
-- freebsd10: http://localhost:8007/
-
-Available boxes are:
-
-- `vagrant up ubuntu`
-- `vagrant up debian8`
-- `vagrant up debian7`
-- `vagrant up debian6`
-- `vagrant up centos7`
-- `vagrant up centos6`
-- `vagrant up freebsd10`
-
-Any specific configuration has to be done manually (Postgres or Mysql).
+The virtual machine is based on Ubuntu 14.04 with PHP 5.5.