Skip to content

Accessing Settings

Jeff Felchner edited this page Jan 8, 2018 · 7 revisions

Once Chamber loads your settings from your YAML files, you will have access to those settings through the Chamber class.

Example:

Given a settings.yml file containing:

smtp:
  server:   "example.com"
  username: "my_user"
  password: "my_pass"

can be accessed as follows:

Chamber[:smtp][:server]
# => example.com

or via object notation syntax:

Chamber.env.smtp.server
# => example.com

Note: The entirety of the Wiki will use object notation for consistency.

Clone this wiki locally