Module: Cloudfront::Utils::ConfigurationChecker
- Included in:
- Helpers::Aliases, Helpers::CacheBehavior, Helpers::CacheBehaviors, Helpers::DownloadDistribution, Helpers::Invalidation, Helpers::Logging, Helpers::Origin, Helpers::OriginAccessIdentity, Helpers::Origins, Helpers::S3Origin, Helpers::StreamingDistribution, Helpers::TrustedSigners
- Defined in:
- lib/cloudfront/utils/configuration_checker.rb
Instance Attribute Summary collapse
-
#error_messages ⇒ Object
readonly
Returns the value of attribute error_messages.
Instance Method Summary collapse
Instance Attribute Details
#error_messages ⇒ Object (readonly)
Returns the value of attribute error_messages.
4 5 6 |
# File 'lib/cloudfront/utils/configuration_checker.rb', line 4 def @error_messages end |
Instance Method Details
#check_configuration ⇒ Object
12 13 14 15 16 |
# File 'lib/cloudfront/utils/configuration_checker.rb', line 12 def check_configuration unless valid? raise Cloudfront::Exceptions::DistributionConfigurationException.new "Configuration error : \n #{@error_messages.join "\n"}" end end |
#valid? ⇒ Boolean
6 7 8 9 10 |
# File 'lib/cloudfront/utils/configuration_checker.rb', line 6 def valid? (@error_messages ||= []).clear validate !@error_messages.any? end |