nitos_testbed_rc 2.0.5 → 2.0.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MDg1M2ZkMDhiZDYzNjljNWNjNjQyMjBjMTc3MTcxMmE4ODMxODVkOA==
4
+ OWY5MDliODZjNmY3N2NiYWM2MWU5ZDMzYTk5MTZhZDNmY2JjMTQzOA==
5
5
  data.tar.gz: !binary |-
6
- MmI4ODcxNmQzZjM5ZGMyZDk1OWQxZjE0YTM4ZjY1NTgwNDhlODA4MA==
6
+ MDJjZjQ1YzU4MjhiNDhlYzQ0ZmU4ODc3YTI2NTkyMzE0MjFhODY4OQ==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- ZGMyNjhkNzExNGRjMDUyZmY0ODA2ZTFiMzgwNDEzZDg0OGU0ZjZmMWQ4OTUw
10
- OGI4NjNiZTc5MWE1OGNjOTUzMzA5OWI4NjY5MTQ1ZTJlYmEzZWNmNjljNTZk
11
- ZGU2YTFkZjRkNWMxOTU1NTdjZGJiZjc4NDQ1YmJiYjAxZjBhMTM=
9
+ ZmIyM2YwZDU2ZGQ4MTZjNTM1MzlmYzUzMDA3OTM1MmUzNjY0YWNmYTExN2Ey
10
+ OTQ2NjhiYTQ5ZTU4ODk4NzI3ZDc3N2U1ZTc0MTA1NWZhYmMzNTAzMzRlZGZm
11
+ NjJmYzkyYTIwY2U3NjYwOTJiMDNkYjY5M2VjZTYyMWQ5M2ExODE=
12
12
  data.tar.gz: !binary |-
13
- MTA2OTc3MmVkMmVhNmMyMjg2NDUxNzBmYWQzMjY1ZjgzM2QxOTVkYjVjMDMw
14
- NWU4OWE4YTExOTliMjJjOGE5NjQwYzllODQ4MWMzNmYzOWNkZDYwNjliYTlk
15
- YTg2YTI1ODY4N2EzNjhjMWU3NGEzODU4MGQ3Mzk0YjYxZTAzZTM=
13
+ NzRkYWI3ZmNjYjg3NjJmYWIzNzg5NjA5OTcwMmNkM2ZiODY3OGY0YjI2ZTY1
14
+ ODEyMGRlMTdjM2U2MWVjODRkMTk1NTMxMDk3MzkwZmNlOTg2ZWI5NTc1ZjM4
15
+ ZjYyNDFhODBmZjIwOWFjNmI2M2M1MDQ3MTNiNWM2ZjI2OGIyOTA=
data/bin/omf6 CHANGED
@@ -425,9 +425,14 @@ def create_imagezip_client(comm, fcontroller, cm_controller, node, port, options
425
425
  client = reply_msg.resource
426
426
  client.on_subscribed do
427
427
  client.on_message do |client_msg|
428
+ puts "==== #{client_msg.inspect}"
428
429
  if client_msg.operation == :inform
429
430
  if client_msg.read_property("event") == "STDOUT"
430
431
  # print "#{client_msg.read_property("msg")}"
432
+ elsif client_msg.read_property("event") == 'BAD_FORMAT'
433
+ puts "ERROR: #{client_msg.read_property("msg")}"
434
+ cm_controller.configure(state: {node: node.to_sym, status: :stop, last_action: options[:last_action]})
435
+ shut_down(comm)
431
436
  elsif client_msg.read_property("event") == "EXIT"
432
437
  stop_saving()
433
438
  puts "INFO:"
@@ -497,6 +502,8 @@ def create_imagezip_client(comm, fcontroller, cm_controller, node, port, options
497
502
  cm_controller.configure(state: {node: node.to_sym, status: :start_without_pxe, last_action: options[:last_action]})
498
503
  end
499
504
  end
505
+ elsif client_msg.operation == :error
506
+ puts "aaa"
500
507
  end
501
508
  end
502
509
  end
@@ -34,7 +34,7 @@ module OmfRc::ResourceProxy::ImagezipClient #Imagezip client
34
34
  debug "Received message '#{client.opts.inspect}'"
35
35
  sleep 1
36
36
  if error_msg = client.opts.error_msg
37
- res.inform(:error,{
37
+ client.inform(:error,{
38
38
  event_type: "AUTH",
39
39
  exit_code: "-1",
40
40
  node_name: client.property.node_topic,
@@ -52,20 +52,34 @@ module OmfRc::ResourceProxy::ImagezipClient #Imagezip client
52
52
  host = Net::Telnet.new("Host" => client.property.multicast_interface.to_s, "Timeout" => false, "Telnetmode" => true)
53
53
 
54
54
  output = ''
55
+ error = nil
55
56
  host.cmd(command.to_s) do |c|
56
57
  print "#{c}"
57
58
  if c.include? 'compressed'
58
59
  output = c
60
+ elsif c.include?("Filesystem specific error")
61
+ error = 'Filesystem not supported by the save mechanism (ext4 not supported).'
59
62
  end
60
63
  end
61
64
 
62
- client.inform(:status, {
63
- status_type: 'FRISBEE',
64
- event: "EXIT",
65
- app: client.property.app_id,
66
- node: client.property.node_topic,
67
- msg: output
68
- }, :ALL)
65
+ if error
66
+ puts "****"
67
+ client.inform(:error,{
68
+ event_type: "ERROR",
69
+ event: "BAD_FORMAT",
70
+ exit_code: "-2",
71
+ node_name: client.property.node_topic,
72
+ msg: error
73
+ }, :ALL)
74
+ else
75
+ client.inform(:status, {
76
+ status_type: 'FRISBEE',
77
+ event: "EXIT",
78
+ app: client.property.app_id,
79
+ node: client.property.node_topic,
80
+ msg: output
81
+ }, :ALL)
82
+ end
69
83
  host.close
70
84
  end
71
85
 
@@ -43,7 +43,7 @@ module OmfRc::ResourceProxy::User
43
43
  end
44
44
 
45
45
  opts[:xmpp][:script_user] = res.property.username
46
- opts[:xmpp][:server] = res.topics.first.address.split('@').last
46
+ # opts[:xmpp][:server] = res.topics.first.address.split('@').last
47
47
 
48
48
  File.open("#{path}/omf_script_conf.yaml", "w") {|f| f.write(opts.to_yaml) }
49
49
 
data/lib/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  module NITOS
2
2
  module TestbedRc
3
- VERSION = "2.0.5"
3
+ VERSION = "2.0.6"
4
4
  end
5
5
  end
@@ -19,9 +19,9 @@ Gem::Specification.new do |s|
19
19
  s.require_paths = ["lib"]
20
20
 
21
21
  # specify any dependencies here; for example:
22
- s.add_runtime_dependency "omf_common", "~> 6.1.3"
23
- s.add_runtime_dependency "omf_rc", "~> 6.1.3"
24
- s.add_runtime_dependency "nokogiri", "~> 1.6.0"
25
- s.add_runtime_dependency "progress_bar", "~> 1.0.3"
26
- s.add_runtime_dependency "net-ssh", "~> 2.8.0"
22
+ s.add_runtime_dependency "omf_common", "= 6.2.3"
23
+ s.add_runtime_dependency "omf_rc", "= 6.2.3"
24
+ s.add_runtime_dependency "nokogiri", "= 1.6.0"
25
+ s.add_runtime_dependency "progress_bar", "= 1.0.3"
26
+ s.add_runtime_dependency "net-ssh", "= 2.8.0"
27
27
  end
metadata CHANGED
@@ -1,83 +1,83 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nitos_testbed_rc
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.5
4
+ version: 2.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - NITOS
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-07-07 00:00:00.000000000 Z
11
+ date: 2017-12-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: omf_common
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 6.1.3
19
+ version: 6.2.3
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 6.1.3
26
+ version: 6.2.3
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: omf_rc
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 6.1.3
33
+ version: 6.2.3
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ~>
38
+ - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 6.1.3
40
+ version: 6.2.3
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: nokogiri
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ~>
45
+ - - '='
46
46
  - !ruby/object:Gem::Version
47
47
  version: 1.6.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ~>
52
+ - - '='
53
53
  - !ruby/object:Gem::Version
54
54
  version: 1.6.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: progress_bar
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - ~>
59
+ - - '='
60
60
  - !ruby/object:Gem::Version
61
61
  version: 1.0.3
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - ~>
66
+ - - '='
67
67
  - !ruby/object:Gem::Version
68
68
  version: 1.0.3
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: net-ssh
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - ~>
73
+ - - '='
74
74
  - !ruby/object:Gem::Version
75
75
  version: 2.8.0
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - ~>
80
+ - - '='
81
81
  - !ruby/object:Gem::Version
82
82
  version: 2.8.0
83
83
  description: NITOS testbed resource controllers that support a. Chassis manager cards,
@@ -142,7 +142,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
142
142
  version: '0'
143
143
  requirements: []
144
144
  rubyforge_project: nitos_testbed_rc
145
- rubygems_version: 2.1.11
145
+ rubygems_version: 2.6.12
146
146
  signing_key:
147
147
  specification_version: 4
148
148
  summary: NITOS testbed resource controllers.