lib/blavosync/recipes/content_rsync.rb in blavosync-0.2.1 vs lib/blavosync/recipes/content_rsync.rb in blavosync-0.2.2
- old
+ new
@@ -10,10 +10,14 @@
remote_domain = fetch(:domain)
end
if exists?(:rsync_domain)
remote_domain = fetch(:rsync_domain)
end
- system("rsync -avz -e ssh '#{user}@#{remote_domain}:#{content_path}' '#{rails_root}/tmp/'")
+ if exists?(:user)
+ remote_user = fetch(:user)
+ end
+
+ system("rsync -avz -e ssh '#{[remote_user, remote_domain].join("@")}:#{content_path}' '#{rails_root}/tmp/'")
end
desc <<-DESC
Creates a symlink to public/system from tmp/system
DESC
\ No newline at end of file