Send http(s) git url instead NFS path

This commit is contained in:
Vladimir Sharshov 2012-11-08 13:41:07 +04:00
parent d885d6be6b
commit 08b3099b90
1 changed files with 4 additions and 4 deletions

View File

@ -116,10 +116,10 @@ class Project < ActiveRecord::Base
end
def git_project_address
#host ||= EventLog.current_controller.request.host_with_port rescue ::Rosa::Application.config.action_mailer.default_url_options[:host]
#protocol ||= EventLog.current_controller.request.protocol rescue "http"
#Rails.application.routes.url_helpers.project_url(self.owner.uname, self.name, :host => host, :protocol => protocol) + ".git"
path
host ||= EventLog.current_controller.request.host_with_port rescue ::Rosa::Application.config.action_mailer.default_url_options[:host]
protocol = APP_CONFIG['mailer_https_url'] ? "https" : "http" rescue "http"
Rails.application.routes.url_helpers.project_url(self.owner.uname, self.name, :host => host, :protocol => protocol) + ".git"
#path #share by NFS
end
def build_for(platform, repository_id, user, arch = 'i586', auto_publish = false, mass_build_id = nil, priority = 0)