jeudi 12 juillet 2018

Ember Deploy CLI - not reading .env files

Trying to deploy to an AWS S3 deployment target using the ember-cli-deploy plugin.

Have tested deploying using AWS key and secrets hardcoded in the /config/deploy.js file, which worked fine, so can confirm that it is something to do with my environment file setup.

The files are stored in the root of the directory (as per docs). Have tested .env and target-specific variables such as .env.deploy.develop. These files contain the AWS in the following format:

AWS_KEY​=ABC
AWS_SECRET​=ABC123

Running the deployment process (i.e. ember deploy develop --activate --verbose) with the environment file setup results in the errors detailed in my previous question on the matter.

Fairly sure that there is only need for the .env file, since the AWS keys and secrets are simply referenced in the deploy.js file in the following manner (w/o any target conditions):

let credsConfig = {
  accessKeyId: process.env.AWS_KEY,
  secretAccessKey: process.env.AWS_SECRET,
};

Any clues as to what's going on here would be much appreciated!




Aucun commentaire:

Enregistrer un commentaire