sumodev 0.2.1 → 0.2.2

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: 19d19f3d3f4b2a8f0d46bfd05f8bf5a758aee175
4
- data.tar.gz: 7b9034006911044632470d90c997879e9eda2305
3
+ metadata.gz: 089ef41613c50e3b181da222401ea5f115df3f05
4
+ data.tar.gz: 8295eb6155fa7dcae9562e5c525f22bd407d7ab8
5
5
  SHA512:
6
- metadata.gz: a28e04a6ae8a864a0dc9a6da035c1ea651c460ec11702284e04887626e20d4c4e04c3b8893c3a279f82723af74d72436c4dae1409cdadcca945eac0ed20691c9
7
- data.tar.gz: cb813992a4e318fb82b64bc1e4d7bd473c8c1b318af3435d34b7f8697da8a09f2a9d1ab75f0e8653931084eacefcacbe6347e104700754382d1627d33166b0b2
6
+ metadata.gz: 56a04fc4624b75087acbbeecc7c28ce4eac67037d9392c77fe7eb743aea60163ca4e5d11ee9f5f857b15bde4713c33b9bd9c20c50c2cb41e645a7dd16ab0582a
7
+ data.tar.gz: e2ef394e378287eec0483def2472a5011503ea3b07f139557834fd22ddf90885aa8be1e58c01cd3a59b1c92db778263debeadf4217137b48d3842a0c8e2503de
@@ -61,6 +61,31 @@ class Sumodev::Commands::Box < Sumodev::Command
61
61
  say("No Sumofile found! Please define one so the correct versions will be used!", :red) && exit(1)
62
62
  end
63
63
 
64
+ desc 'install', "Installs everything required to use the box command"
65
+ def install
66
+ # install vagrant plugins
67
+ %x(vagrant plugin install vagrant-ohai)
68
+ %x(vagrant plugin install vagrant-omnibus)
69
+
70
+ # install .sumorc file
71
+ File.open(File.expand_path("~/.sumorc"), 'w') do |f|
72
+ f.write <<-SUMORC
73
+ export SUMO_VAGRANT_PATH=""
74
+ SUMORC
75
+ end unless File.exists?(File.expand_path("~/.sumorc"))
76
+
77
+ # setup resolver
78
+ File.open("/tmp/vagrant-resolver", 'w') do |f|
79
+ f.write <<-RESOLVER
80
+ # Created by sumo command
81
+ nameserver 10.11.12.13
82
+ port 53
83
+ RESOLVER
84
+ end
85
+
86
+ %x(sudo mv /tmp/vagrant-resolver /etc/resolver/vagrant)
87
+ end
88
+
64
89
  desc 'your_command', "Runs your command on the correct box"
65
90
  def your_command(*args)
66
91
  say "Use sumo box <command> you bloody idiot, eg: sumo box ssh"
@@ -1,3 +1,3 @@
1
1
  module Sumodev
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sumodev
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jan De Poorter
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-12-31 00:00:00.000000000 Z
11
+ date: 2014-01-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport