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

Problem in genrating migration files #2

Closed
abdullah-afzal opened this issue Jul 6, 2023 · 0 comments
Closed

Problem in genrating migration files #2

abdullah-afzal opened this issue Jul 6, 2023 · 0 comments

Comments

@abdullah-afzal
Copy link

abdullah-afzal commented Jul 6, 2023

I want to ask how you are generating and populating the migration files like this one in this project.

Sorry for the above question, I have done it by creating a "ormconfig.ts" file having following contents:

import { DataSource } from "typeorm";
​
export const connectionSource = new DataSource({
   migrationsTableName: 'migrations',
   type: 'postgres',
   host: 'localhost',
   port: 5432,
   username: 'name',
   password: 'pass',
   database: 'my-medusa-store-db',
   logging: true,
   // synchronize: true,
   // name: 'default',
   entities: ['src/models/*.ts'],
   migrations: ['src/migrations/*{.ts,.js}']
});
​
// export default connectionSource
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant