Storage profiles are stored at the company level and used to route a companies files to the correct storage location. There are three storage profiles right now: default
govcloud
and apse2
with the main regions being us-east-1
, us-gov-west-1
, and ap-southeast-2
respectively.
- Switch the company storage profile in the rails_console:
Company.find(<company_id>).update(storage_profile_key: <new_profile_name>)
- Use the storage profile migrator to migrate old files to the new profile
migrator = Storage::CompanyStorageProfileMigrator.new(company_id: , new_profile:)
migrator.perform
Caveat - There are certain scenarios where a storage profile has been switched for a company when it has items in sidekiq on a different profile. For this reason the company should have no file workers in sidekiq when the profile switch is made.
- Go to
procore.com/super/companies/new
and create a company. Find the company_id on the home page. - Use that company_id to switch the storage_profile `Company.find(<company_id>).update(storage_profile_key: <storage_profile>)