Created
February 18, 2016 00:49
-
-
Save kylog/2888fefb4d87bcaf38e3 to your computer and use it in GitHub Desktop.
strict_environment_mode logic
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if !strict_environment_mode | |
| # do like today | |
| else | |
| if environment was not specified and use_cached_catalog == false | |
| # do like today | |
| elif environment was specified and use_cached_catalog == true | |
| if environment != catalog.environment | |
| raise | |
| end | |
| else # we have only one source of environment, woot | |
| # use that, skipping node request, and failing if catalog convergence doesn't happen | |
| end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment