bring up your old project... you need the api structure!
This commit is contained in:
parent
044fa66910
commit
5a064b4e07
|
@ -15,9 +15,9 @@ $ git submodule update
|
||||||
Set db admin, user, pass, etc in 'Makefile'.
|
Set db admin, user, pass, etc in 'Makefile'.
|
||||||
Spin up the database service and create users:
|
Spin up the database service and create users:
|
||||||
```bash
|
```bash
|
||||||
# $ make database-clean # opt
|
# $ make database-clean # opt, removes docker services, not data
|
||||||
$ make database-service
|
$ make database-service
|
||||||
$ make database-users
|
$ make database-users # only first time; user data persists too
|
||||||
```
|
```
|
||||||
|
|
||||||
Populate the database with data form files:
|
Populate the database with data form files:
|
||||||
|
|
|
@ -11,7 +11,7 @@ services:
|
||||||
MONGO_INITDB_ROOT_USERNAME: ${DB_ADM_USER}
|
MONGO_INITDB_ROOT_USERNAME: ${DB_ADM_USER}
|
||||||
MONGO_INITDB_ROOT_PASSWORD: ${DB_ADM_PASS}
|
MONGO_INITDB_ROOT_PASSWORD: ${DB_ADM_PASS}
|
||||||
volumes:
|
volumes:
|
||||||
- ${HOME}/mongo_container/data/:/data/
|
- ${HOME}/mongo_container/data/:/data/db
|
||||||
|
|
||||||
mongo-express:
|
mongo-express:
|
||||||
image: mongo-express
|
image: mongo-express
|
||||||
|
|
|
@ -28,7 +28,7 @@ def frames_from_db_entry(dbent):
|
||||||
tids=[_full_tid(srl["to"])]
|
tids=[_full_tid(srl["to"])]
|
||||||
) for srl in srlarr
|
) for srl in srlarr
|
||||||
],
|
],
|
||||||
sentences=[dbent["tokens"]],
|
sentences=[(dbent["sid"], dbent["tokens"])], # [(ssj_id, {word: _, lemma: _, msd: _}), ...]
|
||||||
)]
|
)]
|
||||||
return frames
|
return frames
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user