Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit bb287b0

Browse files
rename scripts
1 parent ab2229f commit bb287b0

File tree

4 files changed

+10
-8
lines changed

4 files changed

+10
-8
lines changed

README.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,17 +62,15 @@ Setup your Elasticsearch instance and ensure that it is up and running.
6262

6363
1. Follow *Configuration* section to update config values, like database, etc ..
6464
2. Goto *UBahn-api*, run `npm i` and `npm run lint`
65-
3. Run the migrations - `npm run migrations up`. This will create the database, the tables and insert mock data into the database. You will then run `npm run migrate-db-to-es` to migrate the data to elasticsearch from the database
66-
4. Startup server `node app.js` or `npm run start`
65+
3. Run the migrations - `npm run migrations up`. This will create the database, the tables.
66+
4. Then run `npm run insert-data` and insert mock data into the database.
67+
5. You will then run `npm run migrate-db-to-es` to migrate the data to elasticsearch from the database
68+
6. Startup server `node app.js` or `npm run start`
6769

6870
## Migrations
6971

7072
Migrations are located under the `./scripts/db/` folder. Run `npm run migrations up` and `npm run migrations down` to execute the migrations or remove the earlier ones
7173

72-
## Import seed data
73-
74-
Run `npm run seeds-up` to import data from `./scripts/db/data`.
75-
7674
## Import data from QLDB
7775

7876
Make sure `QLDB_NAME`, `AWS_REGION`, `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY` are set in your environment

docker-pgsql-es/sample.env

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
DB_NAME=ubahn-db
2+
DB_USERNAME=postgres
3+
DB_PASSWORD=<password>
4+
DB_HOST=postgres
5+
DB_PORT=5432

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,10 @@
66
"scripts": {
77
"start": "node app.js",
88
"lint": "standard \"**/*.js\"",
9-
"insert-data": "node scripts/db/genData.js",
109
"delete-data": "node scripts/db/dropAll.js",
1110
"migrate-db-to-es": "node scripts/db/dumpDbToEs.js",
1211
"migrations": "node scripts/db/migrations.js",
13-
"seeds-up": "node scripts/db/seedUp.js",
12+
"insert-data": "node scripts/db/insert-data.js",
1413
"migrate-qldb-to-pg": "node scripts/db/migrateQldbToPg.js"
1514
},
1615
"repository": {
File renamed without changes.

0 commit comments

Comments
 (0)