Skip to content
This repository has been archived by the owner on Nov 30, 2022. It is now read-only.

Accept an arbitrary path to /migrations in config #613

Closed
wants to merge 4 commits into from

Conversation

PSalant726
Copy link
Contributor

@PSalant726 PSalant726 commented Jun 8, 2022

Purpose

PyPI installs the fidesops /migrations directory outside of the package source tree, in a sibling directory of /fidesops. This enables a way to specify a path to DB migrations that exists outside of the /fidesops package source tree.

Changes

  • config.package.PATH --> config.package.MIGRATION_PATH
  • If provided, fidesops does not prescribe the directory structure within the MIGRATIONS_PATH, other than that a /migrations directory must exist
  • Dramatically reduce the os package import volume in config.py

Checklist

  • Update CHANGELOG.md file
    • Merge in main so the most recent CHANGELOG.md file is being appended to
    • Add description within the Unreleased section in an appropriate category. Add a new category from the list at the top of the file if the needed one isn't already there.
    • Add a link to this PR at the end of the description with the PR number as the text. example: #1
  • Applicable documentation updated (guides, quickstart, postman collections, tutorial, fidesdemo, database diagram.
  • If docs updated (select one):
    • documentation complete, or draft/outline provided (tag docs-team to complete/review on this branch)
    • documentation issue created (tag docs-team to complete issue separately)
  • Good unit test/integration test coverage
  • This PR contains a DB migration. If checked, the reviewer should confirm with the author that the down_revision correctly references the previous migration before merging
  • The Run Unsafe PR Checks label has been applied, and checks have passed, if this PR touches any external services

Ticket

Fixes #612

@PSalant726 PSalant726 added bug Something isn't working dev experience Enhancements to the overall DX run unsafe ci checks Triggers running of unsafe CI checks labels Jun 8, 2022
@PSalant726 PSalant726 self-assigned this Jun 8, 2022
Copy link
Contributor

@sanders41 sanders41 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me. Should we wait to merge while we discuss #612 since the decision there may change this?

@PSalant726
Copy link
Contributor Author

Closing in favor of #615 and a resulting PR, re: #612 (comment).

@PSalant726 PSalant726 closed this Jun 8, 2022
@PSalant726 PSalant726 deleted the any-path-to-migrations branch June 8, 2022 04:50
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working dev experience Enhancements to the overall DX run unsafe ci checks Triggers running of unsafe CI checks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Accept an arbitrary path to /migrations in config
2 participants