Reputation: 71
I made following configuration:
In Centos 6.4 I installed redmine 2.3.2, apache2 passenger module and SVN 1.7.11. I configured to run redmine on apache and so far everything is working perfectly.
In Windows server 2008 I installed VisualSVN Server compatible with SVN 1.7. so far everything is working perfectly.
Problem when I try to integrate svn installed on windows server with redmine installed Centos, I get the error:
svn: E230001: Unable to connect to a repository at URL 'https://xxx.xxx.x.xxx/svn/myrepo'
svn: E230001: Server SSL certificate untrusted
I've accepted the certifcate permanently to the folder /var/www/svn
I pointed to the certificate in permanent settings file /var/www/redmine/lib/redmine/scm/ adapters/subversion_adapter.rb
def credentials_string
str =''
str << "- config-dir /var/www/svn - username # {shell_quote (@ login)}" [email protected]?
str << "- password # {shell_quote (@ password)}" [email protected]? | | @ Password.blank?
str << "- trust-server-cert - no-auth-cache - non-interactive"
str
end
And the time to click on the tab redmine repository get the exception above.
How do I fix this problem? Any idea?
Upvotes: 1
Views: 2477
Reputation: 71
After doing several tests, I found that the problem is in apache, ie, by running by 3000 with the command ruby script / rails server webrick-e production works normally but when run by apache gives the error above. How to fix it in apache?
Problem solved. The following settings were made
File /var/www/redmine/lib/redmine/scm/adapters/subversion_adapter.rb
def credentials_string
str = ''
str << " --username #{shell_quote(@login)}" unless @login.blank?
str << " --password #{shell_quote(@password)}" unless @login.blank? || @password.blank?
str << " --no-auth-cache --non-interactive --config-dir /tmp/subversion_config"
str
end
And to accept the certificate permanently so I did:
svn ls --config-dir /tmp/subversion_config --config-option config:auth:store-auth-creds=yes https://xxx.xxx.x.xxx/svn/myrepo/
Added permission folder:
chown-R apache: apache /tmp/subversion_config
References:
Upvotes: 1
Reputation: 30662
Make sure that the certificate on VisualSVN Server matches it's hostname (it's case-sensitive)! --trust-server-cert
won't automatically accept certificate with non-matching hostname since it's considered insecure.
Upvotes: 0