【发布时间】:2018-08-19 14:05:45
【问题描述】:
我在 heroku 中定义了 2 个环境变量。运行 heroku config 显示:
=== handandfootserver Config Vars
PASSWORD: xxxxxxxxxxx
PORT: 3001
但是,当我运行我的 node.js 应用程序并运行 console.log(process.env) 时,我得到:
{ NODE_ENV: 'production' }
版本:节点 - 8.9.1,npm - 默认
代码用 ES6 编写并使用 webpack 构建。构建成功。
如果您需要更多信息,请告诉我。
【问题讨论】:
标签: node.js heroku environment-variables