vagrant-guestip 0.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 6b272b9555306bdebf0cf262d1f2f334681ee482
4
+ data.tar.gz: 939d6c1f9815126106ebd43efe7a3ce063c2a578
5
+ SHA512:
6
+ metadata.gz: 2c93878009585e8ca03f1588a63f87873cae2dd44951c3f12745f53e0efecee9f033ce292c054b0c19801633b5daf004820422f8b10f6b68921d33ca16203e24
7
+ data.tar.gz: f5cf5ee281bb96d4dd228b45439136073fa35005b4eec7eb44a6a58b191ec0336221fc193c5c1a5ebd106a05dfb0c489130d2da4901619d9ad7da03b734c6fea
@@ -0,0 +1,26 @@
1
+ .idea/
2
+ *.iml
3
+ *.gem
4
+ *.rbc
5
+ .bundle
6
+ .config
7
+ .yardoc
8
+ Gemfile.lock
9
+ InstalledFiles
10
+ _yardoc
11
+ coverage
12
+ doc/
13
+ lib/bundler/man
14
+ pkg
15
+ rdoc
16
+ spec/reports
17
+ test/tmp
18
+ test/version_tmp
19
+ tmp
20
+ *.bundle
21
+ *.so
22
+ *.o
23
+ *.a
24
+ mkmf.log
25
+ Vagrantfile
26
+ .vagrant/
data/Gemfile ADDED
@@ -0,0 +1,9 @@
1
+ source 'https://rubygems.org'
2
+
3
+ group :development do
4
+ gem 'vagrant', git: 'https://github.com/mitchellh/vagrant.git'
5
+ end
6
+
7
+ group :plugins do
8
+ gem 'vagrant-guestip', path: '.'
9
+ end
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2015 Michael Kuzmin
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,9 @@
1
+ # vagrant-guestip plugin
2
+
3
+ ## Installation
4
+
5
+ $ vagrant plugin install vagrant-guestip
6
+
7
+ ## Usage
8
+
9
+ $ vagrant ip
@@ -0,0 +1,2 @@
1
+ require "bundler/gem_tasks"
2
+
@@ -0,0 +1,17 @@
1
+ module VagrantPlugins
2
+ module GuestIP
3
+ class Command < Vagrant.plugin(2, :command)
4
+ def self.synopsis
5
+ 'outputs IP address of a guest machine'
6
+ end
7
+
8
+ def execute
9
+ with_target_vms(nil, {:single_target=>true}) do |machine|
10
+ ip = machine.guest.capability(:read_ip_address)
11
+ message = ENV['TEAMCITY_VERSION'] ? "##teamcity[setParameter name='env.VAGRANT_IP' value='#{ip}']" : ip
12
+ @env.ui.info(message)
13
+ end
14
+ end
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,12 @@
1
+ module VagrantPlugins
2
+ module GuestIP
3
+ class Plugin < Vagrant.plugin(2)
4
+ name 'guestip'
5
+
6
+ command('ip', primary: false) do
7
+ require_relative 'command'
8
+ Command
9
+ end
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,15 @@
1
+ Gem::Specification.new do |spec|
2
+ spec.name = 'vagrant-guestip'
3
+ spec.version = '0.1'
4
+ spec.authors = ['Michael Kuzmin']
5
+ spec.email = ['mkuzmin@gmail.com']
6
+ spec.summary = 'Vagrant plugin for obtaining IP address of guest machine'
7
+ spec.homepage = 'https://github.com/mkuzmin/vagrant-gusetip'
8
+ spec.license = 'MIT'
9
+
10
+ spec.files = `git ls-files -z`.split("\x0")
11
+ spec.require_paths = ['lib']
12
+
13
+ spec.add_development_dependency 'bundler', '~> 1.6'
14
+ spec.add_development_dependency 'rake'
15
+ end
metadata ADDED
@@ -0,0 +1,80 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: vagrant-guestip
3
+ version: !ruby/object:Gem::Version
4
+ version: '0.1'
5
+ platform: ruby
6
+ authors:
7
+ - Michael Kuzmin
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2015-01-06 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ~>
18
+ - !ruby/object:Gem::Version
19
+ version: '1.6'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ~>
25
+ - !ruby/object:Gem::Version
26
+ version: '1.6'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - '>='
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - '>='
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ description:
42
+ email:
43
+ - mkuzmin@gmail.com
44
+ executables: []
45
+ extensions: []
46
+ extra_rdoc_files: []
47
+ files:
48
+ - .gitignore
49
+ - Gemfile
50
+ - LICENSE.txt
51
+ - README.md
52
+ - Rakefile
53
+ - lib/command.rb
54
+ - lib/vagrant-guestip.rb
55
+ - vagrant-guestip.gemspec
56
+ homepage: https://github.com/mkuzmin/vagrant-gusetip
57
+ licenses:
58
+ - MIT
59
+ metadata: {}
60
+ post_install_message:
61
+ rdoc_options: []
62
+ require_paths:
63
+ - lib
64
+ required_ruby_version: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - '>='
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ required_rubygems_version: !ruby/object:Gem::Requirement
70
+ requirements:
71
+ - - '>='
72
+ - !ruby/object:Gem::Version
73
+ version: '0'
74
+ requirements: []
75
+ rubyforge_project:
76
+ rubygems_version: 2.2.2
77
+ signing_key:
78
+ specification_version: 4
79
+ summary: Vagrant plugin for obtaining IP address of guest machine
80
+ test_files: []