Package: release.debian.org Severity: normal Tags: jessie User: release.debian....@packages.debian.org Usertags: pu
This fixes an issue when upgrading from 3.0~20140825-5 (original version release with jessie) to any of the later stable updates, when there are multiple redmine instances or when the `default` has been removed. This has been fixed in unstable on 3.2.1-2. The diff for jessie is attached. -- System Information: Debian Release: stretch/sid APT prefers unstable APT policy: (500, 'unstable'), (500, 'testing'), (1, 'experimental') Architecture: amd64 (x86_64) Kernel: Linux 4.4.0-1-amd64 (SMP w/4 CPU cores) Locale: LANG=pt_BR.UTF-8, LC_CTYPE=pt_BR.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) -- Antonio Terceiro <terce...@debian.org>
diff --git a/debian/changelog b/debian/changelog index c4db2f7..ec0e42a 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +redmine (3.0~20140825-8~deb8u3) jessie; urgency=medium + + * gemfile-adjustments.patch: load all database drivers for all Redmine + instances (Closes: #819815) + + -- Antonio Terceiro <terce...@debian.org> Sun, 03 Apr 2016 20:47:00 -0300 + redmine (3.0~20140825-8~deb8u2) jessie-security; urgency=high * Security update. Includes fixes for the following vulnerabilities: diff --git a/debian/patches/gemfile-adjustments.patch b/debian/patches/gemfile-adjustments.patch index 3a2f6e1..0db0aa3 100644 --- a/debian/patches/gemfile-adjustments.patch +++ b/debian/patches/gemfile-adjustments.patch @@ -37,24 +37,33 @@ end end -@@ -46,8 +46,11 @@ end +@@ -46,12 +46,16 @@ end # configuration file require 'erb' require 'yaml' -database_file = File.join(File.dirname(__FILE__), "config/database.yml") -if File.exist?(database_file) -+# FIXME duplicating logic in config/application.rb -+ENV['X_DEBIAN_SITEID'] ||= 'default' -+ENV['RAILS_ETC'] = "/etc/redmine/#{ENV['X_DEBIAN_SITEID']}" -+database_file = File.join(ENV['RAILS_ETC'], "database.yml") -+if File.readable?(database_file) ++seen_adapters = {} ++Dir['{config,/etc/redmine/*}/database.yml'].select do |f| ++ File.exists?(f) ++end.each do |database_file| database_config = YAML::load(ERB.new(IO.read(database_file)).result) adapters = database_config.values.map {|c| c['adapter']}.compact.uniq if adapters.any? -@@ -78,21 +81,6 @@ else - warn("Please configure your config/database.yml first") - end - + adapters.each do |adapter| ++ next if seen_adapters[adapter] ++ seen_adapters[adapter] = true + case adapter + when 'mysql2' + gem "mysql2", "~> 0.3.11", :platforms => [:mri, :mingw] +@@ -74,23 +78,6 @@ if File.exist?(database_file) + else + warn("No adapter found in config/database.yml, please configure it first") + end +-else +- warn("Please configure your config/database.yml first") +-end +- -group :development do - gem "rdoc", ">= 2.4.2" - gem "yard" @@ -68,8 +77,6 @@ - # For running UI tests - gem "capybara", "~> 2.1.0" - gem "selenium-webdriver" --end -- + end + local_gemfile = File.join(File.dirname(__FILE__), "Gemfile.local") - if File.exists?(local_gemfile) - eval_gemfile local_gemfile
signature.asc
Description: PGP signature