Sha256: 9fac47511c7d8a453ec1a1dec174bba31faf687d5e5a6a135895ed37006a540f

Contents?: true

Size: 700 Bytes

Versions: 1

Compression:

Stored size: 700 Bytes

Contents

module Bosh::Bootstrap::NetworkProviders
  class AWS
    attr_reader :provider_client

    def initialize(provider_client)
      @provider_client = provider_client
    end

    def perform
      security_groups.each do |name, ports|
        provider_client.create_security_group(name.to_s, name.to_s, ports: ports)
      end
    end

    protected
    def security_groups
      {
        ssh: 22,
        dns_server: 53,
        bosh_nats_server: 4222,
        bosh_agent_https: 6868,
        bosh_blobstore: 25250,
        bosh_director: 25555,
        bosh_registry: 25777
      }
    end
  end
end
Bosh::Bootstrap::NetworkProviders.register_provider("aws", Bosh::Bootstrap::NetworkProviders::AWS)

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bosh-bootstrap-0.11.6 lib/bosh-bootstrap/network_providers/aws.rb