FEATURE: Add hidden setting to disable configuration of inventory bucket

This commit is contained in:
Gerhard Schlager 2020-01-14 17:23:12 +01:00
parent 12d2fe7ff6
commit c351ffe580
2 changed files with 6 additions and 1 deletions

View File

@ -7,7 +7,9 @@ module Jobs
class UpdateS3Inventory < ::Jobs::Base class UpdateS3Inventory < ::Jobs::Base
def execute(args) def execute(args)
return unless SiteSetting.enable_s3_inventory? && SiteSetting.Upload.enable_s3_uploads return unless SiteSetting.enable_s3_inventory? &&
SiteSetting.Upload.enable_s3_uploads &&
SiteSetting.s3_configure_inventory_policy
[:upload, :optimized].each do |type| [:upload, :optimized].each do |type|
s3_inventory = S3Inventory.new(Discourse.store.s3_helper, type) s3_inventory = S3Inventory.new(Discourse.store.s3_helper, type)

View File

@ -1174,6 +1174,9 @@ files:
default: true default: true
enable_s3_inventory: enable_s3_inventory:
default: false default: false
s3_configure_inventory_policy:
default: true
hidden: true
allow_profile_backgrounds: allow_profile_backgrounds:
client: true client: true
default: true default: true