Skip to content

Load Fixtures

Kuan Fan edited this page Oct 11, 2019 · 24 revisions

page owner: TFRS DevOps Specialist

Tables Created/Updated by Migration 0023 (Core Data Load)

  • permission (Tightly coupled to application logic. Supported permissions)
  • credit_trade_status (Tightly coupled to application logic. All possible credit trade statuses)
  • credit_trade_type (eg Buy/Sell)
  • credit_trade_zero_reason (Other, Affiliate)
  • organization_actions_type (eg Buy/Sell)
  • organization_type (Government, Fuel Supplier)
  • organization_status (Active, Archived)
  • role (FSUser, FSManager, Admin, GovUser, GovDirector)
  • organization (adds Government only)
  • organization_balance (set government balance)
  • role_permission (setup initial role to permission mappings)
  • signing_authority_assertion (at least one is required for the app to operate. it is a placeholder)
  • compliance_period (at least one is required for the app to operate. it is a placeholder)

Notably NOT created by Migration 0023, because they are implementation specific:

  • Operational Fuel Suppliers and Users
  • Real Compliance Periods and Signing Authority Assertions

These are created by the operational data load scripts. After migration 0024 is run, they can be installed like:

  • python manage.py load_ops_data path_to_script.py OR from Minio:
  • python manage.py load_ops_data --minio --minio-bucket operational_scripts_bucket script_name.py