bcome 0.3.3 → 0.3.4
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/documentation/example_non_shell_scripts/examples_script_basic_usage.rb +5 -5
- data/documentation/example_non_shell_scripts/examples_script_entire_estate.rb +2 -2
- data/documentation/example_non_shell_scripts/examples_script_platform_level.rb +2 -2
- data/lib/bcome.rb +1 -1
- data/lib/bcome/version.rb +1 -1
- data/lib/helpers/selections.rb +2 -2
- data/lib/ssh.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e5b0ebe228e2ae3369ca4014f664c632673b0a9e
|
4
|
+
data.tar.gz: 42cb66fcc2405cc00e45d39bbc4b21565f3ae23b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2f6990c0d55e964ffd126a4d5ab7de6a41d440cb90e3674838a384ff9841b3d07b357c656d67aa14088439ef3aa3f9eb1e6e5ade4b142ae7ce82ac54b826e5d8
|
7
|
+
data.tar.gz: 4ff8bd98c95b1d727c016afc7f8b93210e06c3d4424eeef1c7f2bc340e6d000672f0e26f927b9c16c46c0009858dbe3a6993e9562458314f6baa901717dc113a
|
@@ -12,7 +12,7 @@ current_context = B_PIN.node
|
|
12
12
|
|
13
13
|
raise "Demo script is for an Environment context" unless current_context.is_a?(Bcome::Node::Environment)
|
14
14
|
|
15
|
-
puts "You have loaded into a context of type #{current_context.class}, named #{current_context.identifier}\n".
|
15
|
+
puts "You have loaded into a context of type #{current_context.class}, named #{current_context.identifier}\n".cyan
|
16
16
|
|
17
17
|
## The 'machines' accessor
|
18
18
|
puts "Iterating over servers found at the current context level\n".informational
|
@@ -25,24 +25,24 @@ machines.each {|machine|
|
|
25
25
|
}
|
26
26
|
|
27
27
|
## Playing with a machine
|
28
|
-
puts "\nDoing things with the machines:".
|
28
|
+
puts "\nDoing things with the machines:".cyan
|
29
29
|
|
30
30
|
raise "Cannot proceed with demo, no machines found" unless machines.any?
|
31
31
|
|
32
32
|
machine = machines.first
|
33
33
|
|
34
34
|
## Command execution
|
35
|
-
puts "\n\nExecuting a command on #{machine.identifier}".
|
35
|
+
puts "\n\nExecuting a command on #{machine.identifier}".cyan
|
36
36
|
command = machine.run("whoami")
|
37
37
|
|
38
38
|
## File upload
|
39
|
-
puts "\n\nFile upload".
|
39
|
+
puts "\n\nFile upload".cyan
|
40
40
|
local_path = "~/Desktop/foo"
|
41
41
|
remote_path = "/home/guillaume"
|
42
42
|
machine.put(local_path, remote_path)
|
43
43
|
|
44
44
|
## File download
|
45
|
-
puts "\n\nFile download".
|
45
|
+
puts "\n\nFile download".cyan
|
46
46
|
machine.get(remote_path)
|
47
47
|
|
48
48
|
exit 0
|
@@ -29,12 +29,12 @@ platforms.each {|platform|
|
|
29
29
|
environments = platform.environments
|
30
30
|
|
31
31
|
environments.each {|environment|
|
32
|
-
puts "Environment:".
|
32
|
+
puts "Environment:".cyan + "\s#{environment.identifier}".informational
|
33
33
|
|
34
34
|
# Machines within this enironment
|
35
35
|
machines = environment.machines
|
36
36
|
machines.each { |machine|
|
37
|
-
puts "Identifier: ".
|
37
|
+
puts "Identifier: ".cyan + "\s#{machine.identifier}"
|
38
38
|
}
|
39
39
|
|
40
40
|
}
|
@@ -23,12 +23,12 @@ puts "Platform has #{all_machines.size} machines".informational
|
|
23
23
|
environments = platform.environments
|
24
24
|
|
25
25
|
environments.each {|environment|
|
26
|
-
puts "Environment:".
|
26
|
+
puts "Environment:".cyan + "\s#{environment.identifier}".informational
|
27
27
|
|
28
28
|
# Machines within this enironment
|
29
29
|
machines = environment.machines
|
30
30
|
machines.each { |machine|
|
31
|
-
puts "Identifier: ".
|
31
|
+
puts "Identifier: ".cyan + "\s#{machine.identifier}"
|
32
32
|
}
|
33
33
|
|
34
34
|
}
|
data/lib/bcome.rb
CHANGED
data/lib/bcome/version.rb
CHANGED
data/lib/helpers/selections.rb
CHANGED
data/lib/ssh.rb
CHANGED
@@ -23,7 +23,7 @@ class ::Bcome::Ssh
|
|
23
23
|
|
24
24
|
::Net::SSH.start(instance.ip_address, ssh_user, :proxy => proxy, :keys => ssh_keys, :paranoid => false) do |ssh|
|
25
25
|
ssh_exec!(ssh, command)
|
26
|
-
output_append("(#{instance.identifier})$".cyan + ">\s#{command.command} (#{command.pretty_result})\n")
|
26
|
+
output_append("\n(#{instance.identifier})$".cyan + ">\s#{command.command} (#{command.pretty_result})\n")
|
27
27
|
output_append("#{command.output}")
|
28
28
|
ssh.close
|
29
29
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bcome
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Guillaume Roderick (Webzakimbo)
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-07-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk
|
@@ -101,19 +101,19 @@ dependencies:
|
|
101
101
|
- !ruby/object:Gem::Version
|
102
102
|
version: 1.3.3
|
103
103
|
- !ruby/object:Gem::Dependency
|
104
|
-
name:
|
104
|
+
name: pmap
|
105
105
|
requirement: !ruby/object:Gem::Requirement
|
106
106
|
requirements:
|
107
107
|
- - '='
|
108
108
|
- !ruby/object:Gem::Version
|
109
|
-
version: 1.
|
109
|
+
version: 1.1.1
|
110
110
|
type: :runtime
|
111
111
|
prerelease: false
|
112
112
|
version_requirements: !ruby/object:Gem::Requirement
|
113
113
|
requirements:
|
114
114
|
- - '='
|
115
115
|
- !ruby/object:Gem::Version
|
116
|
-
version: 1.
|
116
|
+
version: 1.1.1
|
117
117
|
description: Provides a console interface for traversing a hierarchy of platforms
|
118
118
|
-> environment -> servers, and exposes common administration tools for the managemenent
|
119
119
|
either of individual servers, or groups or servers. System is driven from simple
|