Sha256: 37116b369b6d404af62f3aa36e813bff03979422aada0f227be3cc02246ff6f4
Contents?: true
Size: 811 Bytes
Versions: 1
Compression:
Stored size: 811 Bytes
Contents
require "fog" require "log4r" require "restclient" require "json" require_relative "../openstack_client" module VagrantPlugins module Openstack module Action # This action connects to Openstack, verifies credentials work, and # puts the Openstack connection object into the `:openstack_compute` key # in the environment. class ConnectOpenstack def initialize(app, env) @app = app @logger = Log4r::Logger.new("vagrant_openstack::action::connect_openstack") end def call(env) # Get the configs config = env[:machine].provider_config client = OpenstackClient::new() env[:openstack_client] = client client.authenticate(env) @app.call(env) end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
vagrant-openstack-provider-0.1 | lib/vagrant-openstack/action/connect_openstack.rb |