updated configs and added nginx note in readme
This commit is contained in:
parent
06b24d85b7
commit
5d7957c5fb
@ -8,4 +8,8 @@ Mongodo running on your system
|
|||||||
npm install
|
npm install
|
||||||
npm start
|
npm start
|
||||||
|
|
||||||
Logging is current defaulting to debug during dev. Bitcore logging is preceded by a timestamp. Bcoin logging with [info]
|
Logging is current defaulting to debug during dev. Bitcore logging is preceded by a timestamp. Bcoin logging with [info]
|
||||||
|
|
||||||
|
# Nginx
|
||||||
|
|
||||||
|
The API is configured to run on port 3000 by default. Use the standard Nginx reverse proxy to flip http to https and handle ssl certs.
|
||||||
@ -1,5 +1,17 @@
|
|||||||
const config = {
|
const config = {
|
||||||
mongodb: 'mongodb://localhost/bitcore',
|
bcoin: {
|
||||||
|
network: 'main',
|
||||||
|
db: 'leveldb',
|
||||||
|
checkpoints: true,
|
||||||
|
workers: true,
|
||||||
|
logLevel: 'info',
|
||||||
|
},
|
||||||
|
mongodb: {
|
||||||
|
uri: 'mongodb://localhost/bitcore',
|
||||||
|
options: {
|
||||||
|
useMongoClient: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
module.exports = config;
|
module.exports = config;
|
||||||
|
|||||||
3
index.js
3
index.js
@ -1,11 +1,12 @@
|
|||||||
const node = require('./lib/node');
|
const node = require('./lib/node');
|
||||||
|
const config = require('./config/config.js');
|
||||||
const logger = require('./lib/logger');
|
const logger = require('./lib/logger');
|
||||||
const Api = require('./lib/api');
|
const Api = require('./lib/api');
|
||||||
|
|
||||||
logger.log('debug',
|
logger.log('debug',
|
||||||
'Debug mode started');
|
'Debug mode started');
|
||||||
|
|
||||||
Api.listen(3000, () => {
|
Api.listen(config.api.port, () => {
|
||||||
logger.log('debug',
|
logger.log('debug',
|
||||||
'listening on port 3000');
|
'listening on port 3000');
|
||||||
});
|
});
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user