From 5b3a2600fb80bd0fd5331774775f9af914000b05 Mon Sep 17 00:00:00 2001
From: Stefan Galinski <stefan@sgalinski.de>
Date: Sun, 1 Mar 2015 20:39:32 +0100
Subject: [PATCH] [BUGFIX] Download the git repository before TYPO3 is provided

---
 recipes/default.rb | 44 ++++++++++++++++++++++----------------------
 1 file changed, 22 insertions(+), 22 deletions(-)

diff --git a/recipes/default.rb b/recipes/default.rb
index 310e92f..db1c537 100644
--- a/recipes/default.rb
+++ b/recipes/default.rb
@@ -116,6 +116,28 @@ web_app node['typo3_site']['hostname'] do
 	server_aliases node['typo3_site']['server_aliases']
 end
 
+#######################
+### Provide Sources ###
+#######################
+
+if node['typo3_site']['repository'] != ''
+	ssh_known_hosts_entry node['typo3_site']['repository_hostname'] do
+		port node['typo3_site']['repository_port']
+	end
+
+	git "#{node['typo3_site']['webroot']}/#{node['typo3_site']['hostname']}" do
+		repository node['typo3_site']['repository']
+		remote 'origin'
+		revision 'HEAD'
+		reference 'master'
+		timeout 100000
+		user 'vagrant'
+		group 'vagrant'
+		action :checkout
+		ssh_wrapper '/home/vagrant/ssh_wrapper.sh'
+	end
+end
+
 ###################
 ### Setup TYPO3 ###
 ###################
@@ -157,28 +179,6 @@ bash 'Setup TYPO3' do
 	action :run
 end
 
-#######################
-### Provide Sources ###
-#######################
-
-if node['typo3_site']['repository'] != ''
-	ssh_known_hosts_entry node['typo3_site']['repository_hostname'] do
-		port node['typo3_site']['repository_port']
-	end
-
-	git "#{node['typo3_site']['webroot']}/#{node['typo3_site']['hostname']}" do
-		repository node['typo3_site']['repository']
-		remote 'origin'
-		revision 'HEAD'
-		reference 'master'
-		timeout 100000
-		user 'vagrant'
-		group 'vagrant'
-		action :checkout
-		ssh_wrapper '/home/vagrant/ssh_wrapper.sh'
-	end
-end
-
 ###########################################
 ### Provide site specific configuration ###
 ###########################################
-- 
GitLab