Open danawoodman opened 6 years ago
@Frijol @HipsterBrown any suggestions?
I've never tried deploying with a .env file, but my guess is that dotenv
is looking in the wrong place: https://github.com/motdotla/dotenv#path, try this:
require('dotenv').config({path: path.join(__dirname, '.env')});
@rwaldron thanks I'll give this a shot and report back!
Hi @danawoodman! Did you manage to make it work by specifying the path with __dirname
? I'm stuck with the same issue. Thanks!
ok just to confirm, specifying the path works. Thanks!!!
I am trying to use environment configs to allow me to develop, test and deploy to my Tessel without hardcoding API keys etc.
I have attempted to use node-config as well as dotenv and while both work great in my Jest test suite and in development, the configs don't work on the Tessel. I have added my
.env
file to.tesselinclude
and triple checked everything but nothing is working.Are environment configs support on Tessel's VM/OS? If so, what am I missing?
Thanks!