aboutsummaryrefslogtreecommitdiffstats
path: root/packages/pipeline/src/ormconfig.ts
diff options
context:
space:
mode:
authorAlex Browne <stephenalexbrowne@gmail.com>2018-11-13 08:40:20 +0800
committerAlex Browne <stephenalexbrowne@gmail.com>2018-12-05 06:24:48 +0800
commit329c68f610843ebded9ca31fc9cd6f3eed744a8e (patch)
tree166b089d14a10e47e206a971998597960e267790 /packages/pipeline/src/ormconfig.ts
parent6fb333f2003a67277a7605332f146adb2758cdd0 (diff)
downloaddexon-sol-tools-329c68f610843ebded9ca31fc9cd6f3eed744a8e.tar
dexon-sol-tools-329c68f610843ebded9ca31fc9cd6f3eed744a8e.tar.gz
dexon-sol-tools-329c68f610843ebded9ca31fc9cd6f3eed744a8e.tar.bz2
dexon-sol-tools-329c68f610843ebded9ca31fc9cd6f3eed744a8e.tar.lz
dexon-sol-tools-329c68f610843ebded9ca31fc9cd6f3eed744a8e.tar.xz
dexon-sol-tools-329c68f610843ebded9ca31fc9cd6f3eed744a8e.tar.zst
dexon-sol-tools-329c68f610843ebded9ca31fc9cd6f3eed744a8e.zip
Configure TypeORM for migrations. Add new package.json scripts.
Diffstat (limited to 'packages/pipeline/src/ormconfig.ts')
-rw-r--r--packages/pipeline/src/ormconfig.ts25
1 files changed, 5 insertions, 20 deletions
diff --git a/packages/pipeline/src/ormconfig.ts b/packages/pipeline/src/ormconfig.ts
index 39b496ace..95c27eeba 100644
--- a/packages/pipeline/src/ormconfig.ts
+++ b/packages/pipeline/src/ormconfig.ts
@@ -20,28 +20,13 @@ const entities = [
Transaction,
];
-export const testConfig: ConnectionOptions = {
- type: 'sqlite',
- database: 'database.sqlite',
- synchronize: true,
- logging: false,
- entities,
- migrations: ['./lib/src/migrations/**/*.js'],
- cli: {
- entitiesDir: 'lib/src/entities',
- migrationsDir: 'lib/src/migrations',
- },
-};
-
-export const deployConfig: ConnectionOptions = {
+const config: ConnectionOptions = {
type: 'postgres',
url: process.env.ZEROEX_DATA_PIPELINE_DB_URL,
- synchronize: true,
+ synchronize: false,
logging: false,
entities,
- migrations: ['./lib/src/migrations/**/*.js'],
- cli: {
- entitiesDir: 'lib/src/entities',
- migrationsDir: 'lib/src/migrations',
- },
+ migrations: ['./lib/migrations/**/*.js'],
};
+
+module.exports = config as ConnectionOptions;