diff --git a/package.json b/package.json index 2b7ca8a..243d5ac 100644 --- a/package.json +++ b/package.json @@ -71,7 +71,8 @@ "TWITTER_CONSUMER_KEY": "@twitter-consumer-key", "TWITTER_CONSUMER_SECRET": "@twitter-consumer-secret", "TWITTER_ACCESS_TOKEN_KEY": "@twitter-access-token-key", - "TWITTER_ACCESS_TOKEN_SECRET": "@twitter-access-token-secret" + "TWITTER_ACCESS_TOKEN_SECRET": "@twitter-access-token-secret", + "LOGS_SECRET_PREFIX": "@logs_secret_prefix" } }, "lint-staged": { diff --git a/server.js b/server.js index 957e9fd..28cc343 100644 --- a/server.js +++ b/server.js @@ -9,7 +9,10 @@ const dev = process.env.NODE_ENV !== 'production' && !process.env.NOW const app = next({ dev }) const handle = app.getRequestHandler() -require('now-logs')(process.env.NOW_URL) +if (!dev) { + const LOGS_ID = `${process.env.LOGS_SECRET_PREFIX}:${process.env.NOW_URL}` + require('now-logs')(LOGS_ID) +} function wrap(handler) { return (req, res) =>