Everipedia Backend Data-Access API
This code has only been tested on Ubuntu 18.04.
Users of Ubuntu >16.04 can attempt to use the install/ubuntu_setup.sh script. Users of Mac OS X or Windows will have to install and initialize MongoDB and IPFS manually.
$ npm install
$ cd install
$ ./ubuntu_setup.sh
$ cd ..
You will find a SAMPLE.env
file in the project root. Copy or rename this to .env
(still in the project root) and set your API keys + other configuration variables as indicated.
# development
$ npm run start
# watch mode
$ npm run start:dev
# incremental rebuild (webpack)
$ npm run webpack
$ npm run start:hmr
# production mode
$ npm run start:prod
There are currently only end-to-end test for the repo. To run:
# end-to-end tests
$ npm run test:e2e
# unit tests - currently not available
$ npm run test
# test coverage - currently not available
$ npm run test:cov
Sometimes you need to disable the Dfuse syncing in development or testing.
To do so, comment out the following line in src/main.ts
:
app.get('EosSyncService').sync();