Project

General

Profile

Actions

Feature #12114

open

Usage of Redmine.pm in combination with an alternative svn config-dir

Added by R Sonnenberg about 12 years ago. Updated about 12 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
SCM
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:

Description

A lot has been written about this issue already, but despite all the helpful answers of everybody on this forum, I did not find a solution to my problem today.

Description

when you need to provide an alternative svn config-dir for your subversion installation (for example, when your apache user needs to permanently accept a self-signed certificate), the only way to do so is by modifying Redmine.pm. If you use alternative methods (for example the existing [scm_subversion_command] in configuration.yml or by changing the SVN_BIN in Redmine.pm), you will receive error messages in your apache error log.

Apache error log states:
sh: 'svn --config-dir /path/to/svnconfig' not found

Even though the comments in configuration.yml state that only the full path to the executable should be added (explaining the error messages we see), I believe a small change to Redmine may make everybody's lives much easier!

Proposed solution

add an additional configuration directive to configuration.yml called [scm_subversion_config_dir] which allows people to set their configuration directory manually and without altering Redmine.pm

Personally, I would like to see this added to the 1.3.x branch of Redmine, since I am on Ubuntu 12.04 LTS and will likely be on this version for quite a while before being able to migrate to Redmine 2.x

Temporary workaround

On line 35 (of the original Redmine.pm shipped with version 1.3.2 from the Ubuntu 12.04 repo), replace:

@sq_bin ||= shell_quote_command

with

@sq_bin ||= shell_quote_command << " --config-dir /usr/share/redmine/svn"

This ensures that the parameter is added to all subversion commands and that it still allows usage of the [scm_subversion_command] option.

Related issue

[[http://www.redmine.org/boards/2/topics/24818?r=33882#message-33882]]

System information

About your application's environment
Ruby version 1.8.7 (x86_64-linux)
RubyGems version 1.8.15
Rack version 1.3
Rails version 2.3.14
Active Record version 2.3.14
Active Resource version 2.3.14
Action Mailer version 2.3.14
Active Support version 2.3.14
Edge Rails revision unknown
Application root /usr/share/redmine
Environment production
Database adapter mysql
Database schema version 20110902000000

Actions #1

Updated by R Sonnenberg about 12 years ago

Alternative workaround

As an alternative solution to this entire issue of accepting self signed certificates permanently, you can also add your own certificate to subversions' list of accepted certificates:

  • Edit the file
    /etc/subversion/servers
  • Add the following line:
    ssl-authority-files = /path/to/your/certificate.pem
Actions

Also available in: Atom PDF