2.0.11 • Published 7 years ago
@grudge/server v2.0.11
@grudge/server
Node server for @grudge/client
Postgres Database
- For developing with the database locally
- install docker
$ docker-compose upin the root
- environment variables should be setup in order to connect or migrate
POSTGRES_USER="username"POSTGRES_PASSWORD="password"POSTGRES_DB="db name"POSTGRES_HOST="127.0.0.1"POSTGRES_PROTOCOL="http"POSTGRES_PORT=5432
- adminer is used in development to inspect the database
- started when
$ docker-compose upis ran - visit
127.0.0.1:8080for the dashboard - use the creditials above to sign in
- started when
- interaction with the database is done with knex
- to migrate the database
$ npm run db:migrate
- to rollback migrations
$ npm run db:rollback
- to make a new migration
$ npm i knex -g$ knex migrate:make migration_name