Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Having troubles to get env.sh working. Settings works as expected #157

Open
exocode opened this issue Jun 16, 2015 · 2 comments
Open

Having troubles to get env.sh working. Settings works as expected #157

exocode opened this issue Jun 16, 2015 · 2 comments

Comments

@exocode
Copy link

exocode commented Jun 16, 2015

As the headline assumes I can't get implemented my env.sh file.

env.sh

export VALUE_FROM_ENV="env_value"
# also tried without the "export" command/prefix

settings.json

    {
      "public": {"VALUE_FROM_SETTINGS": "settings_value"}
    }

in my app/server/smtp.coffee I put this lines of code

    Meteor.startup ->
      if (Meteor.isServer)
        console.log(process.env.VALUE_FROM_ENV) # THIS IS NOT WORKING (undefined)
        console.log(Meteor.settings.VALUE_FROM_SETTINGS) # this is working as expected

I simply started my app with iron run or ìron which outputs the following into the console:

> meteor run --settings /Users/me/Meteor/meteor_template/config/development/settings.json
[[[[[ ~/Meteor/meteor_template/app ]]]]]
=> Started proxy.
=> Started MongoDB.
=> Started your app.
=> App running at: http://localhost:3000/
I20150616-17:04:30.279(2)? env_value
I20150616-17:04:30.280(2)? undefined

What I am doing wrong?

best regards

@exocode
Copy link
Author

exocode commented Jul 27, 2015

sorry for bumping...

@chrisbutler
Copy link
Contributor

@mediatainment i'm seeing this also. going to take a look

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants