Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hardcoded schema name breaks migrations with restricted permissions #7058

Open
lechinoix opened this issue Apr 11, 2024 · 1 comment
Open

Comments

@lechinoix
Copy link

Bug report

Describe the bug

  • I setup my medusa store in my production database in a separate schema and I gave it only permissions on its own schema, but when running migrations I had to remove one hardcoded "public" schema name to make it work

System information

Medusa version (including plugins): 1.3.22
Node.js version:
Database: Postgres
Operating system: MacOS
Browser (if relevant):

Steps to reproduce the behavior

  1. Create a user with GRANT ALL ON SCHEMA medusa TO "medusa-user";
  2. Use this user in DATABASE_URL
  3. Run yarn medusa migrations run
  4. It will fail
@lechinoix
Copy link
Author

I think we just need to remove the schema here and here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant