Method: Bosh::Director::DeploymentPlan::JobAvailabilityZoneParser#check_validity_of
- Defined in:
- lib/bosh/director/deployment_plan/job_availability_zone_parser.rb
#check_validity_of(az_names, job_name) ⇒ Object
24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/bosh/director/deployment_plan/job_availability_zone_parser.rb', line 24 def check_validity_of(az_names, job_name) if az_names.empty? raise JobMissingAvailabilityZones, "Instance group '#{job_name}' has empty availability zones" end az_names.each do |name| unless name.is_a?(String) raise JobInvalidAvailabilityZone, "Instance group '#{job_name}' has invalid availability zone '#{name}', string expected" end end end |