kitchen-rax 0.6.0 → 0.7.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bfc94f8c28140b203dd41eada48141caa8807d70
4
- data.tar.gz: 4c1bd141b46c01a319e0010c65b7e95a0315f34c
3
+ metadata.gz: b767c1b95d1a155d839c9fe33db6ad1272a562e2
4
+ data.tar.gz: 90b3d49c663852757beb77214dd9f4301ad63f35
5
5
  SHA512:
6
- metadata.gz: 1be5b082c84c9a791e3c423a94b88540a83db79ad2c27d5a74cc471a2e023a06b0344e8f028b61e06b21bcb0345c1898646b272580aae12798c2e41d26c925f6
7
- data.tar.gz: 64dfe4131f17ff582bd7143a6726cfea74100aff8ea59f02c229ee19161a573d67dc204c6e1d3565771e7dee1de3325188f02ed57d2ad23069eea0d840ec4f14
6
+ metadata.gz: 34ae87dd6ef8d750a9fe411955424442a66ab75315443aecefcaca59abe06f835538ea3c5953e8353d27061da6d415e43a2a1378bf202dfe2751ee643b4c1b3d
7
+ data.tar.gz: 1cd77efa4eb13c4baae9d0942a8fdc85a9edaad584b50458b5da7d46c0e14c1a5af6ddb6ee5e8987c69a279383ef3bb76ed652fa85cd430d54077a2f2331d532
@@ -15,7 +15,6 @@ module Kitchen
15
15
  default_config :rackspace_region, 'lon'
16
16
  default_config :wait_for, 600
17
17
  default_config :image_id
18
- default_config(:server_name, &:default_name)
19
18
  default_config :networks, nil
20
19
 
21
20
  default_config :rackspace_username do
@@ -70,7 +69,13 @@ module Kitchen
70
69
  end
71
70
 
72
71
  def create_server
73
- server_def = { name: default_name }
72
+ server_name = [
73
+ instance.name.gsub(/\W/, '')[0..14],
74
+ (Etc.getlogin || 'nologin').gsub(/\W/, '')[0..14],
75
+ Socket.gethostname.gsub(/\W/, '')[0..22],
76
+ Array.new(7) { rand(36).to_s(36) }.join
77
+ ].join('-')
78
+ server_def = { name: server_name }
74
79
  [:image_id, :flavor_id].each do |opt|
75
80
  server_def[opt] = config[opt]
76
81
  end
@@ -79,15 +84,6 @@ module Kitchen
79
84
  server.save
80
85
  end
81
86
 
82
- def self.default_name
83
- [
84
- instance.name.gsub(/\W/, '')[0..14],
85
- (Etc.getlogin || 'nologin').gsub(/\W/, '')[0..14],
86
- Socket.gethostname.gsub(/\W/, '')[0..22],
87
- Array.new(7) { rand(36).to_s(36) }.join
88
- ].join('-')
89
- end
90
-
91
87
  def rackconnect_check(server)
92
88
  server.wait_for { metadata.all['rackconnect_automation_status'] == 'DEPLOYED' }
93
89
  puts '(rackconnect automation complete)'
@@ -21,6 +21,6 @@ module Kitchen
21
21
  module Driver
22
22
 
23
23
  # Version string for Rax Kitchen driver
24
- RAX_VERSION = "0.6.0"
24
+ RAX_VERSION = "0.7.0"
25
25
  end
26
26
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kitchen-rax
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Olivier Kouame