mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 08:53:41 +08:00
FEATURE: add toggle for uploads:missing so it can skip external
Validating s3 uploads in uploads:missing can be very expensive, allow to bypass.
This commit is contained in:
parent
c86d2666c4
commit
cb86d8279a
|
@ -589,9 +589,13 @@ task "uploads:missing" => :environment do
|
|||
list_missing_uploads(skip_optimized: ENV['SKIP_OPTIMIZED'])
|
||||
else
|
||||
RailsMultisite::ConnectionManagement.each_connection do |db|
|
||||
if ENV["SKIP_EXTERNAL"] == "1" && Discourse.store.external?
|
||||
puts "#{RailsMultisite::ConnectionManagement.current_db} has uploads stored externally skipping!"
|
||||
else
|
||||
list_missing_uploads(skip_optimized: ENV['SKIP_OPTIMIZED'])
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def list_missing_uploads(skip_optimized: false)
|
||||
|
|
Loading…
Reference in New Issue
Block a user