bebox 0.1.3 → 0.1.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/Gemfile.lock +3 -18
- data/bebox.gemspec +1 -1
- data/lib/bebox.rb +1 -0
- data/lib/bebox/cli.rb +7 -1
- data/lib/bebox/commands/commands_helper.rb +2 -2
- data/lib/bebox/commands/environment_commands.rb +6 -6
- data/lib/bebox/commands/general_commands.rb +2 -2
- data/lib/bebox/commands/node_commands.rb +18 -14
- data/lib/bebox/commands/prepare_commands.rb +17 -14
- data/lib/bebox/commands/profile_commands.rb +8 -8
- data/lib/bebox/commands/provision_commands.rb +7 -7
- data/lib/bebox/commands/role_commands.rb +14 -14
- data/lib/bebox/logger.rb +2 -0
- data/lib/bebox/node.rb +0 -1
- data/lib/bebox/profile.rb +1 -1
- data/lib/bebox/project.rb +1 -1
- data/lib/bebox/vagrant_helper.rb +5 -3
- data/lib/bebox/version.rb +1 -1
- data/lib/bebox/wizards/environment_wizard.rb +5 -5
- data/lib/bebox/wizards/node_wizard.rb +23 -22
- data/lib/bebox/wizards/profile_wizard.rb +24 -25
- data/lib/bebox/wizards/project_wizard.rb +34 -28
- data/lib/bebox/wizards/provision_wizard.rb +13 -12
- data/lib/bebox/wizards/role_wizard.rb +15 -21
- data/lib/i18n/en.yml +198 -0
- data/spec/cli_spec.rb +66 -26
- data/spec/fixtures/commands/environment_help.erb.test +1 -0
- data/spec/fixtures/commands/general_help.erb.test +1 -0
- data/spec/fixtures/commands/in_project_help.erb.test +1 -0
- data/spec/fixtures/commands/node_help.erb.test +1 -0
- data/spec/fixtures/commands/profile_help.erb.test +1 -0
- data/spec/fixtures/commands/role_help.erb.test +1 -0
- data/spec/spec_helper.rb +7 -1
- data/spec/wizards/profile_wizard_spec.rb +12 -0
- metadata +23 -22
- data/spec/fixtures/commands/environment_help.test +0 -1
- data/spec/fixtures/commands/general_help.test +0 -1
- data/spec/fixtures/commands/in_project_help.test +0 -1
- data/spec/fixtures/commands/node_help.test +0 -1
- data/spec/fixtures/commands/profile_help.test +0 -1
- data/spec/fixtures/commands/role_help.test +0 -1
@@ -0,0 +1 @@
|
|
1
|
+
NAME environment - <%= env_desc %> SYNOPSIS rspec [global options] environment list rspec [global options] environment new [environment] rspec [global options] environment remove [environment] COMMANDS list - <%= list_desc %> new - <%= new_desc %> remove - <%= remove_desc %>
|
@@ -0,0 +1 @@
|
|
1
|
+
NAME rspec - <%= program_desc %> SYNOPSIS rspec [global options] command [command options] [arguments...] VERSION <%= version %> GLOBAL OPTIONS --help - Show this message --version - Display the program version COMMANDS help - Shows a list of commands or help for one command new - <%= new_desc %>
|
@@ -0,0 +1 @@
|
|
1
|
+
NAME rspec - <%= program_desc %> SYNOPSIS rspec [global options] command [command options] [arguments...] VERSION <%= version %> GLOBAL OPTIONS --help - Show this message --version - Display the program version COMMANDS environment - <%= env_desc %> help - Shows a list of commands or help for one command node - <%= node_desc %>
|
@@ -0,0 +1 @@
|
|
1
|
+
NAME node - <%= node_desc %> SYNOPSIS rspec [global options] node [command options] list [--all] rspec [global options] node [command options] new rspec [global options] node [command options] remove COMMAND OPTIONS --environment=arg - <%= env_flag_desc %> (default: vagrant) COMMANDS list - <%= list_desc %> new - <%= new_desc %> remove - <%= remove_desc %>
|
@@ -0,0 +1 @@
|
|
1
|
+
NAME profile - <%= profile_desc %> SYNOPSIS rspec [global options] profile list rspec [global options] profile new [-p path] [name] rspec [global options] profile remove COMMANDS list - <%= list_desc %> new - <%= new_desc %> remove - <%= remove_desc %>
|
@@ -0,0 +1 @@
|
|
1
|
+
NAME role - <%= role_desc %> SYNOPSIS rspec [global options] role add_profile rspec [global options] role list rspec [global options] role list_profiles [role_name] rspec [global options] role new [name] rspec [global options] role remove rspec [global options] role remove_profile COMMANDS add_profile - <%= add_profile_desc %> list - <%= list_desc %> list_profiles - <%= list_profiles_desc %> new - <%= new_desc %> remove - <%= remove_desc %> remove_profile - <%= remove_profile_desc %>
|
data/spec/spec_helper.rb
CHANGED
@@ -29,6 +29,12 @@ require_relative '../lib/bebox'
|
|
29
29
|
I18n.enforce_available_locales = false
|
30
30
|
|
31
31
|
RSpec.configure do |config|
|
32
|
+
|
33
|
+
# Initialize internationalization
|
34
|
+
FastGettext.add_text_domain('bebox', path: "#{Dir.pwd}/lib/i18n", type: :yaml)
|
35
|
+
FastGettext.set_locale('en')
|
36
|
+
FastGettext.text_domain = 'bebox'
|
37
|
+
|
32
38
|
config.treat_symbols_as_metadata_keys_with_true_values = true
|
33
39
|
|
34
40
|
config.before(:each) do
|
@@ -36,7 +42,7 @@ RSpec.configure do |config|
|
|
36
42
|
end
|
37
43
|
|
38
44
|
config.after(:each) do
|
39
|
-
|
45
|
+
ENV['RUBY_ENV'] = 'development'
|
40
46
|
end
|
41
47
|
|
42
48
|
# Factory Girl methods
|
@@ -19,6 +19,18 @@ describe 'Test 05: Bebox::ProfileWizard' do
|
|
19
19
|
expect(output).to eq(true)
|
20
20
|
end
|
21
21
|
|
22
|
+
it 'not creates a new profile with invalid name' do
|
23
|
+
invalid_name = '0_profile'
|
24
|
+
output = subject.create_new_profile(profile.project_root, invalid_name, profile.path)
|
25
|
+
expect(output).to eq(nil)
|
26
|
+
end
|
27
|
+
|
28
|
+
it 'not creates a new profile with invalid path' do
|
29
|
+
invalid_path = 'and/00'
|
30
|
+
output = subject.create_new_profile(profile.project_root, profile.name, invalid_path)
|
31
|
+
expect(output).to eq(nil)
|
32
|
+
end
|
33
|
+
|
22
34
|
it 'list profiles with wizard' do
|
23
35
|
Bebox::Profile.stub(:list) {[]}
|
24
36
|
output = subject.list_profiles(profile.project_root)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bebox
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Codescrum
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-09-
|
11
|
+
date: 2014-09-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -24,20 +24,6 @@ dependencies:
|
|
24
24
|
- - '='
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: 10.3.1
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: aruba
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
30
|
-
requirements:
|
31
|
-
- - '='
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: 0.5.4
|
34
|
-
type: :development
|
35
|
-
prerelease: false
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
37
|
-
requirements:
|
38
|
-
- - '='
|
39
|
-
- !ruby/object:Gem::Version
|
40
|
-
version: 0.5.4
|
41
27
|
- !ruby/object:Gem::Dependency
|
42
28
|
name: rspec
|
43
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -192,6 +178,20 @@ dependencies:
|
|
192
178
|
- - '='
|
193
179
|
- !ruby/object:Gem::Version
|
194
180
|
version: 0.6.0
|
181
|
+
- !ruby/object:Gem::Dependency
|
182
|
+
name: fast_gettext
|
183
|
+
requirement: !ruby/object:Gem::Requirement
|
184
|
+
requirements:
|
185
|
+
- - '='
|
186
|
+
- !ruby/object:Gem::Version
|
187
|
+
version: 0.9.0
|
188
|
+
type: :runtime
|
189
|
+
prerelease: false
|
190
|
+
version_requirements: !ruby/object:Gem::Requirement
|
191
|
+
requirements:
|
192
|
+
- - '='
|
193
|
+
- !ruby/object:Gem::Version
|
194
|
+
version: 0.9.0
|
195
195
|
description: |2
|
196
196
|
Bebox is a project born from the necessity of organizing a way to deal with the provisioning of remote servers.
|
197
197
|
Bebox is based on puppet and much like another quite known project Boxen,
|
@@ -261,6 +261,7 @@ files:
|
|
261
261
|
- lib/deb/puppet_3.6.0/ruby1.8_1.8.7.352-2ubuntu1.4_amd64.deb
|
262
262
|
- lib/deb/puppet_3.6.0/ruby_4.8_all.deb
|
263
263
|
- lib/deb/puppet_3.6.0/virt-what_1.11-1_amd64.deb
|
264
|
+
- lib/i18n/en.yml
|
264
265
|
- lib/templates/node/Vagrantfile.erb
|
265
266
|
- lib/templates/node/deploy_vagrant_node.erb
|
266
267
|
- lib/templates/node/node.yml.erb
|
@@ -344,12 +345,12 @@ files:
|
|
344
345
|
- spec/factories/role.rb
|
345
346
|
- spec/fixtures/Capfile.test
|
346
347
|
- spec/fixtures/Gemfile.test
|
347
|
-
- spec/fixtures/commands/environment_help.test
|
348
|
-
- spec/fixtures/commands/general_help.test
|
349
|
-
- spec/fixtures/commands/in_project_help.test
|
350
|
-
- spec/fixtures/commands/node_help.test
|
351
|
-
- spec/fixtures/commands/profile_help.test
|
352
|
-
- spec/fixtures/commands/role_help.test
|
348
|
+
- spec/fixtures/commands/environment_help.erb.test
|
349
|
+
- spec/fixtures/commands/general_help.erb.test
|
350
|
+
- spec/fixtures/commands/in_project_help.erb.test
|
351
|
+
- spec/fixtures/commands/node_help.erb.test
|
352
|
+
- spec/fixtures/commands/profile_help.erb.test
|
353
|
+
- spec/fixtures/commands/role_help.erb.test
|
353
354
|
- spec/fixtures/config/deploy.test
|
354
355
|
- spec/fixtures/config/deploy/environment.test
|
355
356
|
- spec/fixtures/config/deploy/production.test
|
@@ -1 +0,0 @@
|
|
1
|
-
NAME environment - Manage environments for the project. The 'vagrant', 'production' and 'staging' environments are present by default. SYNOPSIS rspec [global options] environment list rspec [global options] environment new [environment] rspec [global options] environment remove [environment] COMMANDS list - List the remote environments in the project new - Add a remote environment to the project remove - Remove a remote environment in the project
|
@@ -1 +0,0 @@
|
|
1
|
-
NAME rspec - Create basic provisioning of remote servers. SYNOPSIS rspec [global options] command [command options] [arguments...] VERSION 0.1.2 GLOBAL OPTIONS --help - Show this message --version - Display the program version COMMANDS help - Shows a list of commands or help for one command new - Create a new bebox project through a simple wizard
|
@@ -1 +0,0 @@
|
|
1
|
-
NAME rspec - Create basic provisioning of remote servers. SYNOPSIS rspec [global options] command [command options] [arguments...] VERSION 0.1.2 GLOBAL OPTIONS --help - Show this message --version - Display the program version COMMANDS environment - Manage environments for the project. The 'vagrant', 'production' and 'staging' environments are present by default. help - Shows a list of commands or help for one command
|
@@ -1 +0,0 @@
|
|
1
|
-
NAME node - Manage nodes for a environment in the project. SYNOPSIS rspec [global options] node [command options] list [--all] rspec [global options] node [command options] new rspec [global options] node [command options] remove COMMAND OPTIONS --environment=arg - Set the environment for nodes (default: vagrant) COMMANDS list - list the nodes in a environment new - Add a node to a environment remove - Remove a node in a environment
|
@@ -1 +0,0 @@
|
|
1
|
-
NAME profile - Manage profiles for the node provisioning phase. SYNOPSIS rspec [global options] profile list rspec [global options] profile new [-p path] [name] rspec [global options] profile remove COMMANDS list - List the profiles in the project new - Add a profile to the project remove - Remove a profile from the project
|
@@ -1 +0,0 @@
|
|
1
|
-
NAME role - Manage roles for the node provisioning phase. SYNOPSIS rspec [global options] role add_profile rspec [global options] role list rspec [global options] role list_profiles [role_name] rspec [global options] role new [name] rspec [global options] role remove rspec [global options] role remove_profile COMMANDS add_profile - Add a profile to a role list - List the roles in the project list_profiles - List the profiles in a role new - Add a role to the project remove - Remove a role from the project remove_profile - Remove a profile from a role
|