Galaxy Client Environment Variable Syntax


#1

Is the syntax for Galaxy client environment variables this:

{
	"galaxy.meteor.com": {
		"env": {
			"ROOT_URL": "",
			"MONGO_URL": "",
			"MONGO_OPLOG_URL": "",
			"MAIL_URL": "",
			"STRIPE_LIVE_SECRET": ""
		}
	},
	"public": {
		"STRIPE_LIVE_PUBLISHABLE": ""
	}
}

or this:

{
	"galaxy.meteor.com": {
		"env": {
			"ROOT_URL": "",
			"MONGO_URL": "",
			"MONGO_OPLOG_URL": "",
			"MAIL_URL": "",
			"STRIPE_LIVE_SECRET": "",
			"public": {
				"STRIPE_LIVE_PUBLISHABLE": ""
			}
		}
	}
}

or something else entirely?


#2

Should be the first one


#3

I tried it, but didn’t get any result in the browser.

Has this worked for you?


#4

FYI: to those who are used to process.env with Node, you have to use Meteor.settings.


#5

I use the first one and can access Meteor.settings.public in my browser