Sha256: eba8cf9170b5fa1e5d4bf773af1d1430c74d5657e39ecfe9ad6509160d05d21c

Contents?: true

Size: 559 Bytes

Versions: 1

Compression:

Stored size: 559 Bytes

Contents

module Beaker
  class EC2Helper
    # Return a list of open ports for testing based on a hosts role
    #
    # @todo horribly hard-coded
    # @param [Array<String>] an array of roles
    # @return [Array<Number>] array of port numbers
    # @api private
    def self.amiports(roles)
      ports = [22]

      if roles.include? 'database'
        ports << 8080
        ports << 8081
      end

      if roles.include? 'master'
        ports << 8140
      end

      if roles.include? 'dashboard'
        ports << 443
      end

      ports
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
beaker-1.10.0 lib/beaker/hypervisor/ec2_helper.rb