Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

540
Views
TypeORM CLI - Cómo ejecutar MIGRACIONES en una BASE DE DATOS ESPECÍFICA

Mi ormconfig.json tiene varias bases de datos, ¿cómo ejecutar migraciones para una base de datos ESPECÍFICA de esta lista? En el siguiente ejemplo, tengo la dev de datos de desarrollo con migraciones ya configuradas, ahora necesito configurar las migraciones para la otra base de datos llamada test .

Quería ejecutar un comando como este:

yarn typeorm migration:run --database test

 // ormconfig.json [ { "name": "dev", "type": "postgres", "host": "localhost", "port": 5432, "username": "postgres", "password": "postgres", "database": "postgres", "synchronize": true, "logging": true, "entities": ["src/typeorm/entity/**/*.ts"], "migrations": ["src/typeorm/migration/**/*.ts"], "subscribers": ["src/typeorm/subscriber/**/*.ts"], "cli": { "entitiesDir": "src/typeorm/entity", "migrationsDir": "src/typeorm/migration", "subscribersDir": "src/typeorm/subscriber" } }, { "name": "test", "type": "postgres", "host": "localhost", "port": 5433, "username": "postgres", "password": "postgres", "database": "postgres", "synchronize": true, "logging": false, "entities": ["src/typeorm/entity/**/*.ts"], "migrations": ["src/typeorm/migration/**/*.ts"], "subscribers": ["src/typeorm/subscriber/**/*.ts"], "cli": { "entitiesDir": "src/typeorm/entity", "migrationsDir": "src/typeorm/migration", "subscribersDir": "src/typeorm/subscriber" } } ]
over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

Solo corre:

yarn typeorm migration:run -c configName donde configName es el name de la configuración en su lista de base de ormconfig.json .

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!