Sha256: d9909f1fb51c2e8a4e5ddfbeb0f50c85bfeb2eb5b49476877e4e9103e9c94ef1

Contents?: true

Size: 808 Bytes

Versions: 4

Compression:

Stored size: 808 Bytes

Contents

require 'log4r'
require 'restclient'
require 'json'

require 'vagrant-openstack-provider/client/keystone'
require 'vagrant-openstack-provider/client/nova'
require 'vagrant-openstack-provider/client/neutron'

module VagrantPlugins
  module Openstack
    class Session
      include Singleton

      attr_accessor :token
      attr_accessor :project_id
      attr_accessor :endpoints

      def initialize
        @token = nil
        @project_id = nil
        @endpoints = {}
      end

      def reset
        initialize
      end
    end

    def self.session
      Session.instance
    end

    def self.keystone
      Openstack::KeystoneClient.instance
    end

    def self.nova
      Openstack::NovaClient.instance
    end

    def self.neutron
      Openstack::NeutronClient.instance
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
vagrant-openstack-provider-0.3.4.pre lib/vagrant-openstack-provider/client/openstack.rb
vagrant-openstack-provider-0.3.3 lib/vagrant-openstack-provider/client/openstack.rb
vagrant-openstack-provider-0.3.2 lib/vagrant-openstack-provider/client/openstack.rb
vagrant-openstack-provider-0.3.0 lib/vagrant-openstack-provider/client/openstack.rb