vagrant-hostmanager 1.8.6 → 1.8.7
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/README.md +7 -7
- data/lib/vagrant-hostmanager/hosts_file/updater.rb +3 -3
- data/lib/vagrant-hostmanager/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 273021939378ee108fee40f695d83d106052d8c1
|
4
|
+
data.tar.gz: 41a2dc129bc330935a9b3220cffb65ef00594a86
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e359ce04cb48c23abb4e1fde31405c4cc302cfc9cf6c1c44252e2804dd74b1b16d3b33ecae4f333f739d081efa29e745b9503bf57c9c341d80ad7f913aec2438
|
7
|
+
data.tar.gz: 389d7c2418f96085b9b6e071be00b61e98df6327b812c81da8b4cd90077c43c54906cb6a150cf53b58421df31358d69f6b45623bec204986d90e36a85df60402
|
data/README.md
CHANGED
@@ -6,17 +6,16 @@ Vagrant Host Manager
|
|
6
6
|
[](https://rubygems.org/gems/vagrant-hostmanager)
|
7
7
|
[](https://twitter.com/intent/tweet?text=Check%20out%20this%20awesome%20Vagrant%20plugin%21&url=https%3A%2F%2Fgithub.com%devopsgroup-io%2Fvagrant-hostmanager&hashtags=vagrant%hostmanager&original_referer=)
|
8
8
|
|
9
|
-
`vagrant-hostmanager` is a plugin that manages the
|
9
|
+
`vagrant-hostmanager` is a Vagrant plugin that manages the `hosts` file on guest machines (and optionally the host). Its goal is to enable resolution of multi-machine environments deployed with a cloud provider where IP addresses are not known in advance.
|
10
10
|
|
11
11
|
Installation
|
12
12
|
------------
|
13
|
-
Install the plugin following the typical Vagrant 1.1 procedure:
|
14
13
|
|
15
14
|
$ vagrant plugin install vagrant-hostmanager
|
16
15
|
|
17
16
|
Usage
|
18
17
|
-----
|
19
|
-
To update the
|
18
|
+
To update the `hosts` file on each active machine, run the following
|
20
19
|
command:
|
21
20
|
|
22
21
|
$ vagrant hostmanager
|
@@ -24,14 +23,14 @@ command:
|
|
24
23
|
The plugin hooks into the `vagrant up` and `vagrant destroy` commands
|
25
24
|
automatically.
|
26
25
|
When a machine enters or exits the running state , all active
|
27
|
-
machines with the same provider will have their
|
26
|
+
machines with the same provider will have their `hosts` file updated
|
28
27
|
accordingly. Set the `hostmanager.enabled` attribute to `true` in the
|
29
28
|
Vagrantfile to activate this behavior.
|
30
29
|
|
31
|
-
To update the host's
|
30
|
+
To update the host's `hosts` file, set the `hostmanager.manage_host`
|
32
31
|
attribute to `true`.
|
33
32
|
|
34
|
-
To update the guests'
|
33
|
+
To update the guests' `hosts` file, set the `hostmanager.manage_guest`
|
35
34
|
attribute to `true`.
|
36
35
|
|
37
36
|
A machine's IP address is defined by either the static IP for a private
|
@@ -159,12 +158,13 @@ visible errors, however the ```hosts``` file will not be updated.
|
|
159
158
|
|
160
159
|
Compatibility
|
161
160
|
-------------
|
162
|
-
This Vagrant plugin has been tested with the following
|
161
|
+
This Vagrant plugin has been tested with the following host and guest operating system combinations.
|
163
162
|
|
164
163
|
Date Tested | Vagrant Version | vagrant-hostmanager Version | Host (Workstation) Operating System | Guest (VirtualBox) Operating System
|
165
164
|
------------|-----------------|-----------------------------|-------------------------------------|--------------------------------------
|
166
165
|
03/23/2016 | 1.8.1 | 1.8.1 | Ubuntu 14.04 LTS | CentOS 7.2
|
167
166
|
03/22/2016 | 1.8.1 | 1.8.1 | OS X 10.11.4 | CentOS 7.2
|
167
|
+
05/03/2017 | 1.9.4 | 1.8.6 | macOS 10.12.4 | Windows Server 2012 R2
|
168
168
|
|
169
169
|
|
170
170
|
Troubleshooting
|
@@ -41,11 +41,11 @@ module VagrantPlugins
|
|
41
41
|
|
42
42
|
if update_file(file, machine, false, line_endings)
|
43
43
|
# upload modified file and remove temporary file
|
44
|
-
machine.communicate.upload(file.to_s,
|
44
|
+
machine.communicate.upload(file.to_s, "/tmp/hosts.#{machine.name}")
|
45
45
|
if windir
|
46
|
-
machine.communicate.sudo("mv -force /tmp/hosts
|
46
|
+
machine.communicate.sudo("mv -force /tmp/hosts.#{machine.name} #{realhostfile}")
|
47
47
|
else
|
48
|
-
machine.communicate.sudo("cat /tmp/hosts > #{realhostfile}")
|
48
|
+
machine.communicate.sudo("cat /tmp/hosts.#{machine.name} > #{realhostfile} && rm /tmp/hosts.#{machine.name}")
|
49
49
|
end
|
50
50
|
end
|
51
51
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vagrant-hostmanager
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.8.
|
4
|
+
version: 1.8.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shawn Dahlen
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2017-
|
12
|
+
date: 2017-07-11 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bundler
|