diff --git a/bootstrap.sh b/bootstrap.sh index 65303e37..f23739ed 100644 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -65,7 +65,7 @@ if [ ! -f /vagrant/config/database.yml ] && [ -f /vagrant/config/database.yml.ex echo -e "\nSetting up your database from config/database.yml...\n" cp config/database.yml.example config/database.yml if [ ! -f db/development.sqlite3 ] && [ ! -f db/test.sqlite3 ]; then - bundle exec rake db:setup + su - vagrant -c "cd /vagrant/; bundle exec rake db:setup" else echo -e "\n\nWARNING: You have already have a development/test database." echo -e "WARNING: Please make sure this database works in this vagrant box!\n\n"