"LEFT JOIN #{Project.table_name} ON #{Document.table_name}.project_id = #{Project.table_name}.id"}
cattr_accessor :storage_path
- @@storage_path = "#{RAILS_ROOT}/files"
+ @@storage_path = Redmine::Configuration['attachments_storage_path'] || "#{RAILS_ROOT}/files"
def validate
if self.filesize > Setting.attachment_max_size.to_i.kilobytes
# default configuration options for all environments
default:
+ # Outgoing emails configuration (see examples above)
email_delivery:
delivery_method: :smtp
smtp_settings:
user_name: "redmine@example.net"
password: "redmine"
+ # Absolute path to the directory where attachments are stored.
+ # The default is the 'files' directory in your Redmine instance.
+ # Your Redmine instance needs to have write permission on this
+ # directory.
+ # Examples:
+ # attachments_storage_path: /var/redmine/files
+ # attachments_storage_path: D:/redmine/files
+ attachments_storage_path:
+
# specific configuration options for production environment
# that overrides the default ones
production: