Patch #24007
openChange plugins directory through the configuration.yml file
Added by Helder Manuel Torres Vieira about 8 years ago. Updated over 7 years ago.
0%
Description
This patch adds the possibility to change the directory "plugins" of the application through the file configuration.yml.
The patch has been tested with the last Trunk version (15839)
Files
config_plugins_path.diff (3.85 KB) config_plugins_path.diff | Helder Manuel Torres Vieira, 2016-10-05 20:17 |
Related issues
Updated by Jean-Philippe Lang about 8 years ago
- Status changed from New to Needs feedback
In the comments, you say that Redmine needs to have write permission on the plugins directory. Why is that? I think it should have read permission only.
Updated by Andrey Lobanov (RedSoft) about 8 years ago
I agree. Why plugins directory should have write permissions?
Updated by Jean-Philippe Lang about 8 years ago
- Category set to Plugin API
- Status changed from Needs feedback to New
- Assignee set to Jean-Philippe Lang
- Target version set to 3.4.0
Updated by Helder Manuel Torres Vieira about 8 years ago
Hello,
Sorry, it was a mistake, i was talking about read permissions (not write).
Thanks
Updated by Jean-Philippe Lang about 8 years ago
- Status changed from New to Closed
Patch committed, thanks.
Updated by Go MAEDA over 7 years ago
- Status changed from Closed to Reopened
config/routes.rb
must be aware of plugins_path
setting.
Index: config/routes.rb
===================================================================
--- config/routes.rb (revision 16528)
+++ config/routes.rb (working copy)
@@ -374,7 +374,7 @@
get 'robots.txt', :to => 'welcome#robots'
- Dir.glob File.expand_path("plugins/*", Rails.root) do |plugin_dir|
+ Dir.glob File.expand_path("#{Redmine::Plugin.directory}/*", Rails.root) do |plugin_dir|
file = File.join(plugin_dir, "config/routes.rb")
if File.exists?(file)
begin
Updated by Anonymous over 7 years ago
I wish that functionality, would be very great for multitenancy environments.
Updated by Jean-Philippe Lang over 7 years ago
- Status changed from Reopened to Closed
Fix committed, thanks.
Updated by Go MAEDA over 7 years ago
- Blocked by Patch #26139: Follow Gemfile's plugin loader as #24007 added
Updated by Go MAEDA over 7 years ago
- Status changed from Closed to Reopened
Reopening this issue because a fix for this feature has been submitted as #26139.
Updated by Sho HASHIMOTO over 7 years ago
Is r16654 correct?
config_plugins_path.diff defines Redmine::Plugin.directory as "Absolute path to the directory where plugins are stored.".
File.expand_path("#{Redmine::Plugin.directory}/*", Rails.root) maybe returns "#{Rails.root}/#{Redmine::Plugin.directory}/*"
Updated by Jean-Philippe Lang over 7 years ago
Sho HASHIMOTO wrote:
Is r16654 correct?
config_plugins_path.diff defines Redmine::Plugin.directory as "Absolute path to the directory where plugins are stored.".
File.expand_path("#{Redmine::Plugin.directory}/*", Rails.root) maybe returns "#{Rails.root}/#{Redmine::Plugin.directory}/*"
No it does not returns that because the first argument is an absolute path. But for clarity, I've removed the second arg that is not used. Thanks for pointing this out.
Updated by Jean-Philippe Lang over 7 years ago
- Assignee deleted (
Jean-Philippe Lang) - Target version deleted (
3.4.0)
The current implementation does not support loading plugin gemfiles (#26139), I've removed the option in the configuration file for 3.4.0
Updated by Mischa The Evil over 7 years ago
- Related to Patch #13927: Reduce coupling between plugins and the "plugins/" directory added