Permalink
Browse files

Test Vagrant image - runs the build pack

  • Loading branch information...
1 parent da6acd9 commit 143f075fc4a5cf7b572efdfe75a24c5b3f57ff5c @lstoll committed Dec 16, 2011
Showing with 38 additions and 0 deletions.
  1. +3 −0 .gitignore
  2. +8 −0 Vagrantfile
  3. +27 −0 provision.sh
View
@@ -0,0 +1,3 @@
+
+.DS_Store
+.vagrant
View
@@ -0,0 +1,8 @@
+Vagrant::Config.run do |config|
+ config.vm.box = "lucid64"
+ config.vm.box_url = "http://files.vagrantup.com/lucid64.box"
+ # Foreman default.
+ config.vm.forward_port("http", 5000, 5000)
+ # config.vm.share_folder("build", "/build", "app")
+ config.vm.provision :shell, :path => "provision.sh"
+end
View
@@ -0,0 +1,27 @@
+#!/bin/bash
+
+apt-get install -y libperl-dev curl
+
+# Cleanup
+echo '---> Cleaning up..'
+rm -rf /app
+rm -rf /lp
+
+mkdir -p /lp/build
+mkdir -p /tmp/lp_cache
+
+cp -R /vagrant/* /lp
+mv /lp/sample_app/* /lp/build/
+rm -rf /lp/sample_app
+
+cd /tmp
+
+echo '---> Running detect..'
+/lp/bin/detect /lp/build
+echo '---> Running compile..'
+/lp/bin/compile /lp/build /tmp/lp_cache
+echo '---> Running release..'
+/lp/bin/release
+echo '---> Moving result in to /app..'
+mv /lp/build /app
+chown -R vagrant:vagrant /app

0 comments on commit 143f075

Please sign in to comment.