Commit 7379ac01 authored by Stan Hu's avatar Stan Hu

Only prune non-LFS files

parent 19557e8c
class RemoveFileUploadsFromRegistry < ActiveRecord::Migration class RemoveFileUploadsFromRegistry < ActiveRecord::Migration
# Previous to GitLab 10.0, GitLab would save attachments/avatars to the wrong # Previous to GitLab 10.1, GitLab would save attachments/avatars to the
# directory. Destroy these entries so they will be downloaded again. # wrong directory (/var/opt/gitlab/gitlab-rails/working). Destroy these
def change # entries so they will be downloaded again.
Geo::FileRegistry.destroy_all def up
Geo::BaseRegistry.connection.execute("DELETE FROM file_registry WHERE file_type != 'lfs'")
end end
end end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment