diff options
-rw-r--r-- | Vagrantfile | 6 | ||||
-rw-r--r-- | vagrant/bootstrap.sh | 19 |
2 files changed, 11 insertions, 14 deletions
diff --git a/Vagrantfile b/Vagrantfile index b685bb5..5da39ab 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -2,8 +2,8 @@ # vi: set ft=ruby : Vagrant.configure("2") do |config| - config.vm.box = "vagrant-archlinux-2013-8" - config.vm.box_url = "https://googledrive.com/host/0B_BLFE4aPn5zUVpyaHdLanVnMTg/vagrant-archlinux-2013-8.box" - config.vm.provision :shell, :path => "vagrant/bootstrap.sh" + config.vm.box = "bento/freebsd-10.3" + config.vm.guest = :freebsd config.vm.network :forwarded_port, host: 4567, guest: 80 + config.vm.provision :shell, :path => "vagrant/bootstrap.sh" end diff --git a/vagrant/bootstrap.sh b/vagrant/bootstrap.sh index 7395aa7..c06b929 100644 --- a/vagrant/bootstrap.sh +++ b/vagrant/bootstrap.sh @@ -1,12 +1,9 @@ -#!/usr/bin/env bash +#!/bin/sh +pkg upgrade -y -q -f +pkg install -y -q ruby rubygem-bundler postgresql93-server postgresql93-client nginx -pacman -Suyq --noconfirm -pacman -Sq ruby gcc make sqlite3 nodejs imagemagick --noconfirm -echo "export GEM_HOME=`gem env gemdir`" > /etc/profile.d/rubygems.sh -source /etc/profile.d/rubygems.sh -gem install bundler --no-rdoc --no-ri --no-user-install -cd /vagrant -./script/setup -cp vagrant/rails.service /usr/lib/systemd/system -systemctl enable rails -systemctl start rails +echo 'postgresql_enable="YES"' >> /etc/rc.conf +echo 'nginx_enable="YES"' >> /etc/rc.conf + +service postgresql initdb +service -R |