fog-vmfusion 0.0.1 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE.md +1 -1
- data/fog-vmfusion.gemspec +4 -1
- data/lib/fog/bin/vmfusion.rb +1 -1
- data/lib/fog/compute/vmfusion.rb +5 -5
- data/lib/fog/compute/vmfusion/server.rb +5 -5
- data/lib/fog/vmfusion.rb +4 -4
- data/lib/fog/vmfusion/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ff705e9d7941cf7325f61ff49d1d0143b288c859
|
4
|
+
data.tar.gz: 7f393eda8515bbe9f03df70f143ad185e408cfd7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d9e229851130d99b576e53aa34a7266c9701de58ceb45bb13572c2971c020e95040841120bdf17ab287eebb5a9438d4c090abfe17926db35a5be65a84a53ce92
|
7
|
+
data.tar.gz: a2231fd9aad8317be47d4c90d841fda0ddfa46d0cb67a30e26f0b8270b259643617dd0f7c659d4c4b3fa78401a4c591804fa1f09f33dcb55f06cf6b26bfb0baa
|
data/LICENSE.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
The MIT License (MIT)
|
2
2
|
|
3
|
-
Copyright (c) 2014-2014 [CONTRIBUTORS.md](https://github.com/fog/fog-
|
3
|
+
Copyright (c) 2014-2014 [CONTRIBUTORS.md](https://github.com/fog/fog-vmfusion/blob/master/CONTRIBUTORS.md)
|
4
4
|
|
5
5
|
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
6
6
|
this software and associated documentation files (the "Software"), to deal in
|
data/fog-vmfusion.gemspec
CHANGED
@@ -14,7 +14,10 @@ Gem::Specification.new do |spec|
|
|
14
14
|
spec.homepage = ""
|
15
15
|
spec.license = "MIT"
|
16
16
|
|
17
|
-
|
17
|
+
files = `git ls-files -z`.split("\x0")
|
18
|
+
files.delete(".hound.yml")
|
19
|
+
spec.files = files
|
20
|
+
|
18
21
|
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
19
22
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
20
23
|
spec.require_paths = ["lib"]
|
data/lib/fog/bin/vmfusion.rb
CHANGED
@@ -14,7 +14,7 @@ module Vmfusion # deviates from other bin stuff to accomodate gem
|
|
14
14
|
hash[key] = case key
|
15
15
|
when :compute
|
16
16
|
Fog::Logger.warning("Vmfusion[:compute] is not recommended, use Compute[:vmfusion] for portability")
|
17
|
-
Fog::Compute.new(:provider =>
|
17
|
+
Fog::Compute.new(:provider => "Vmfusion")
|
18
18
|
else
|
19
19
|
raise ArgumentError, "Unrecognized service: #{key.inspect}"
|
20
20
|
end
|
data/lib/fog/compute/vmfusion.rb
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
module Fog
|
2
2
|
module Compute
|
3
3
|
class Vmfusion < Fog::Service
|
4
|
-
autoload :Server,
|
5
|
-
autoload :Servers,
|
4
|
+
autoload :Server, File.expand_path("../vmfusion/server", __FILE__)
|
5
|
+
autoload :Servers, File.expand_path("../vmfusion/servers", __FILE__)
|
6
6
|
|
7
|
-
model_path
|
7
|
+
model_path "fog/compute/vmfusion"
|
8
8
|
|
9
9
|
model :server
|
10
10
|
collection :servers
|
@@ -17,9 +17,9 @@ module Fog
|
|
17
17
|
|
18
18
|
class Real
|
19
19
|
def initialize(_options = {})
|
20
|
-
require
|
20
|
+
require "fission"
|
21
21
|
rescue LoadError => e
|
22
|
-
retry if require(
|
22
|
+
retry if require("rubygems")
|
23
23
|
raise e.message
|
24
24
|
end
|
25
25
|
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require
|
1
|
+
require "fog/compute/models/server"
|
2
2
|
|
3
3
|
module Fog
|
4
4
|
module Compute
|
@@ -16,7 +16,7 @@ module Fog
|
|
16
16
|
# There is currently no documented model of creating VMs from scratch
|
17
17
|
# sans Fusion's wizard.
|
18
18
|
def save
|
19
|
-
raise Fog::Errors::Error.new(
|
19
|
+
raise Fog::Errors::Error.new("Creating a new vm is not yet supported")
|
20
20
|
end
|
21
21
|
|
22
22
|
# Fussion doesn't have the concept of templates so one just clones
|
@@ -173,7 +173,7 @@ module Fog
|
|
173
173
|
macs(@raw[:fission])
|
174
174
|
end
|
175
175
|
|
176
|
-
# Sets up a
|
176
|
+
# Sets up a convenient way to SSH into a Fusion VM using credentials
|
177
177
|
# stored in your .fog file.
|
178
178
|
|
179
179
|
# Simply spawn an SSH session.
|
@@ -211,7 +211,7 @@ module Fog
|
|
211
211
|
Timeout::timeout(360) do
|
212
212
|
begin
|
213
213
|
Timeout::timeout(8) do
|
214
|
-
Fog::SSH.new(ssh_ip_address, username, credentials.merge(:timeout => 4)).run(
|
214
|
+
Fog::SSH.new(ssh_ip_address, username, credentials.merge(:timeout => 4)).run("pwd")
|
215
215
|
end
|
216
216
|
rescue Errno::ECONNREFUSED
|
217
217
|
sleep(2)
|
@@ -226,7 +226,7 @@ module Fog
|
|
226
226
|
private
|
227
227
|
def ip(fission)
|
228
228
|
first_int = fission.network_info.data.keys.first
|
229
|
-
fission.network_info.data[first_int][
|
229
|
+
fission.network_info.data[first_int]["ip_address"]
|
230
230
|
end
|
231
231
|
|
232
232
|
def macs(fission)
|
data/lib/fog/vmfusion.rb
CHANGED
@@ -1,14 +1,14 @@
|
|
1
|
-
require
|
2
|
-
require
|
1
|
+
require "fog/core"
|
2
|
+
require File.expand_path("../vmfusion/version", __FILE__)
|
3
3
|
|
4
4
|
module Fog
|
5
5
|
module Vmfusion
|
6
6
|
extend Fog::Provider
|
7
7
|
|
8
|
-
service(:compute,
|
8
|
+
service(:compute, "Compute")
|
9
9
|
end
|
10
10
|
|
11
11
|
module Compute
|
12
|
-
autoload :Vmfusion,
|
12
|
+
autoload :Vmfusion, File.expand_path("../compute/vmfusion", __FILE__)
|
13
13
|
end
|
14
14
|
end
|
data/lib/fog/vmfusion/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fog-vmfusion
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Paulo Henrique Lopes Ribeiro
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: fog-core
|