diff --git a/app/uploaders/hyrax/uploaded_file_uploader.rb b/app/uploaders/hyrax/uploaded_file_uploader.rb index 6cfa20f437..b9718709b2 100644 --- a/app/uploaders/hyrax/uploaded_file_uploader.rb +++ b/app/uploaders/hyrax/uploaded_file_uploader.rb @@ -4,21 +4,21 @@ class UploadedFileUploader < CarrierWave::Uploader::Base # Override the directory where uploaded files will be stored. # This is a sensible default for uploaders that are meant to be mounted: def store_dir - configured_upload_path + "#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}" + (configured_upload_path / model.class.to_s.underscore / mounted_as} / model.id).to_s end def cache_dir - configured_cache_path + "#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}" + (configured_cache_path / model.class.to_s.underscore / mounted_as / model.id).to_s end private def configured_upload_path - Hyrax.config.upload_path.call + Pathname.new(Hyrax.config.upload_path.call) end def configured_cache_path - Hyrax.config.cache_path.call + Pathname.new(Hyrax.config.cache_path.call) end end end diff --git a/chart/hyrax/templates/configmap-env.yaml b/chart/hyrax/templates/configmap-env.yaml index 893e0ed941..5324219d49 100644 --- a/chart/hyrax/templates/configmap-env.yaml +++ b/chart/hyrax/templates/configmap-env.yaml @@ -14,12 +14,10 @@ data: {{- if .Values.memcached.enabled }} MEMCACHED_HOST: {{ template "hyrax.memcached.fullname" . }} {{- end }} - {{- if .Values.derivativesVolume.enabled }} HYRAX_BRANDING_PATH: "/app/samvera/branding" HYRAX_DERIVATIVES_PATH: "/app/samvera/derivatives" - HYRAX_CACHE_PATH: "/app/samvera/file_cache" + HYRAX_CACHE_PATH: "/app/samvera/file_cache/" HYRAX_UPLOAD_PATH: "/app/samvera/uploads" - {{- end }} RACK_ENV: production RAILS_ENV: production {{- if .Values.redis.enabled }}