Sha256: 54cc8965e172e14b7c809fe3445db05a2ce10ba9d3376c45c464db835d1af351

Contents?: true

Size: 686 Bytes

Versions: 3

Compression:

Stored size: 686 Bytes

Contents

module Bosh::Bootstrap::NetworkProviders
  class OpenStack
    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)
      end
    end

    protected
    def security_groups
      {
        ssh: 22,
        bosh_nats_server: 4222,
        bosh_agent_http: 6868,
        bosh_blobstore: 25250,
        bosh_director: 25555,
        bosh_registry: 25777
      }
    end
  end
end
Bosh::Bootstrap::NetworkProviders.register_provider("openstack", Bosh::Bootstrap::NetworkProviders::OpenStack)

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
bosh-bootstrap-0.11.2 lib/bosh-bootstrap/network_providers/openstack.rb
bosh-bootstrap-0.11.1 lib/bosh-bootstrap/network_providers/openstack.rb
bosh-bootstrap-0.11.0 lib/bosh-bootstrap/network_providers/openstack.rb