I am using heroku running Parse server 4.4.0. I am unable to enable verbose mode.
logLevel also does not work.
I check many posts that say set VERBOSE=1 but this does not work. what are the option options?
here is my index.js
var express = require('express');
var cors = require('cors');
var ParseServer = require('parse-server').ParseServer;
var path = require('path');
var databaseUri = process.env.DATABASE_URI || process.env.MONGODB_URI;
var api = new ParseServer({
databaseURI: databaseUri,
cloud: process.env.CLOUD_CODE_MAIN || __dirname + '/cloud/main.js',
appId: process.env.APP_ID,
masterKey: process.env.MASTER_KEY,
serverURL: process.env.SERVER_URL ,
javascriptKey: process.env.JAVASCRIPT_KEY,
restAPIKey: process.env.REST_API_KEY,
clientKey: process.env.CLIENT_KEY,
verbose:process.env.VERBOSE,
logLevel: process.env.LOG_LEVEL // VERBOSE, INFO, ERROR, NONE, defaults to INFO
});
var app = express();
app.use(cors());
// Serve static assets from the /public folder
app.use('/public', express.static(path.join(__dirname, '/public')));
// Serve the Parse API on the /parse URL prefix
var mountPath = process.env.PARSE_MOUNT || '/parse';
app.use(mountPath, api);
// Parse Server plays nicely with the rest of your web routes
app.get('/', function(req, res) {
res.status(200).send('Make sure to star the parse-server repo on GitHub!');
});
var port = process.env.PORT || 1337;
var httpServer = require('http').createServer(app);
httpServer.listen(port, function() {
console.log('parse-server-example running on port ' + port + '.');
});
If someone else comes looking for this issue then solution is to delete environment variable LOG_LEVEL.
I don't know why this happens but using logLevel variable does not work it seems May be Parse developers can look at it.
Happy if somebody points out any other solution if there is one.