train 0.21.0 → 0.21.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +13 -2
- data/lib/train/extras/os_detect_arista_eos.rb +7 -3
- data/lib/train/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 27a7512d438219eb926939d6e65b7ca59541d43c
|
4
|
+
data.tar.gz: 525f5ef0734a59e2f3f6fc90296829f34c0d6376
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f2066a11bad5834d56ac6af79f5e49cd48323736ffe66b21df929e6cbe3c6d76f0d55c87a6a906677960c585067c8a47b9873ba4179dda1ce4e497d075d30053
|
7
|
+
data.tar.gz: fada216873d7e08ed9ba259b2fdc6e1dcc652380964900efe359734dcac817e821fe33f9090ff32985b2703055c0d0850067535d6a04bd150c16368c9126dc17
|
data/CHANGELOG.md
CHANGED
@@ -1,7 +1,18 @@
|
|
1
1
|
# Change Log
|
2
2
|
|
3
|
-
## [0.21.
|
4
|
-
[Full Changelog](https://github.com/chef/train/compare/v0.
|
3
|
+
## [0.21.1](https://github.com/chef/train/tree/0.21.1) (2016-11-04)
|
4
|
+
[Full Changelog](https://github.com/chef/train/compare/v0.21.0...0.21.1)
|
5
|
+
|
6
|
+
**Closed issues:**
|
7
|
+
|
8
|
+
- detect\_arista\_eos raises exception against unix host [\#160](https://github.com/chef/train/issues/160)
|
9
|
+
|
10
|
+
**Merged pull requests:**
|
11
|
+
|
12
|
+
- ensure the os detection works in pty mode [\#161](https://github.com/chef/train/pull/161) ([chris-rock](https://github.com/chris-rock))
|
13
|
+
|
14
|
+
## [v0.21.0](https://github.com/chef/train/tree/v0.21.0) (2016-11-04)
|
15
|
+
[Full Changelog](https://github.com/chef/train/compare/v0.20.1...v0.21.0)
|
5
16
|
|
6
17
|
**Implemented enhancements:**
|
7
18
|
|
@@ -9,14 +9,16 @@ module Train::Extras
|
|
9
9
|
module DetectAristaEos
|
10
10
|
def detect_arista_eos
|
11
11
|
if unix_file?('/usr/bin/FastCli')
|
12
|
-
|
12
|
+
cmd = @backend.run_command('FastCli -p 15 -c "show version | json"')
|
13
13
|
@platform[:name] = 'arista_eos_bash'
|
14
14
|
family = 'fedora'
|
15
15
|
else
|
16
|
-
|
16
|
+
cmd = @backend.run_command('show version | json')
|
17
17
|
end
|
18
18
|
|
19
|
-
|
19
|
+
# in PTY mode, stderr is matched with stdout, therefore it may not be empty
|
20
|
+
output = cmd.stdout
|
21
|
+
if cmd.exit_status == 0 && !output.empty?
|
20
22
|
eos_ver = JSON.parse(output)
|
21
23
|
@platform[:name] = @platform[:name] || 'arista_eos'
|
22
24
|
family ||= 'arista_eos'
|
@@ -24,6 +26,8 @@ module Train::Extras
|
|
24
26
|
@platform[:release] = eos_ver['version']
|
25
27
|
@platform[:arch] = eos_ver['architecture']
|
26
28
|
true
|
29
|
+
else
|
30
|
+
false
|
27
31
|
end
|
28
32
|
end
|
29
33
|
end
|
data/lib/train/version.rb
CHANGED