vagrant-managed-servers 0.6.0 → 0.6.1
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/CHANGELOG.md +5 -0
- data/README.md +1 -1
- data/lib/vagrant-managed-servers/action/sync_folders.rb +3 -3
- data/lib/vagrant-managed-servers/plugin.rb +72 -72
- data/lib/vagrant-managed-servers/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: 9ff5143d58f5a2edcfa03ca916fbf19b8b72bb18
|
4
|
+
data.tar.gz: 3d508541cf6cd3655ec1cf3da30f0a2efbd26903
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d2c9f39d7a21a9a3c6756ba567f29dfc1b8c7ff2362af1e9318da099376fb63092b454f6e6a49223ab73a1eaeaf6cb29753920f9e8f97f935008c6960ad5277b
|
7
|
+
data.tar.gz: 1fab8e603951b1fb3c2459895142f1ab20793b5dd7fc2b4d9baa6cdf1e3704ae61cfdbae7af569fc8a1666f005b6c71c1e9f1a8030acc125370794b9269453dc
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,11 @@
|
|
1
1
|
|
2
2
|
# Changelog
|
3
3
|
|
4
|
+
## 0.6.1 (released 2015-04-02)
|
5
|
+
|
6
|
+
* quote ssh usernames to support active directory style `domain/user` logins ([#38](https://github.com/tknerr/vagrant-managed-servers/issues/38), thanks @chrisbaldauf!)
|
7
|
+
* document / validate vagrant 1.6+ compatibility which is required for winrm ([#40](https://github.com/tknerr/vagrant-managed-servers/issues/40), thanks @LiamK for reporting!)
|
8
|
+
|
4
9
|
## 0.6.0 (released 2015-03-16)
|
5
10
|
|
6
11
|
* add missing translation for `vagrant status` ([#35](https://github.com/tknerr/vagrant-managed-servers/issues/35), thanks @warrenseine for reporting!)
|
data/README.md
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
[](https://travis-ci.org/tknerr/vagrant-managed-servers)
|
4
4
|
|
5
|
-
This is a [Vagrant](http://www.vagrantup.com) 1.
|
5
|
+
This is a [Vagrant](http://www.vagrantup.com) 1.6+ plugin that adds a provider for "managed servers" to Vagrant, i.e. servers for which you have SSH access but no control over their lifecycle.
|
6
6
|
|
7
7
|
Since you don't control the lifecycle:
|
8
8
|
* `up` and `destroy` are re-interpreted as "linking" / "unlinking" vagrant with a managed server
|
@@ -65,7 +65,7 @@ module VagrantPlugins
|
|
65
65
|
# Create the guest path
|
66
66
|
env[:machine].communicate.sudo("mkdir -p '#{guestpath}'")
|
67
67
|
env[:machine].communicate.sudo(
|
68
|
-
"chown -R #{ssh_info[:username]} '#{guestpath}'")
|
68
|
+
"chown -R '#{ssh_info[:username]}' '#{guestpath}'")
|
69
69
|
|
70
70
|
# Rsync over to the guest path using the SSH info
|
71
71
|
ssh_key_options = Array(ssh_info[:private_key_path]).map { |path| "-i '#{path}' " }.join
|
@@ -73,9 +73,9 @@ module VagrantPlugins
|
|
73
73
|
command = [
|
74
74
|
"rsync", "--verbose", "--archive", "-z",
|
75
75
|
"--exclude", ".vagrant/", "--exclude", "Vagrantfile",
|
76
|
-
"-e", "ssh -p #{ssh_info[:port]} -o StrictHostKeyChecking=no #{ssh_key_options} #{ssh_proxy_commands}",
|
76
|
+
"-e", "ssh -l '#{ssh_info[:username]}' -p #{ssh_info[:port]} -o StrictHostKeyChecking=no #{ssh_key_options} #{ssh_proxy_commands}",
|
77
77
|
hostpath,
|
78
|
-
"#{ssh_info[:
|
78
|
+
"#{ssh_info[:host]}:#{guestpath}"]
|
79
79
|
|
80
80
|
# we need to fix permissions when using rsync.exe on windows, see
|
81
81
|
# http://stackoverflow.com/questions/5798807/rsync-permission-denied-created-directories-have-no-permissions
|
@@ -1,72 +1,72 @@
|
|
1
|
-
begin
|
2
|
-
require "vagrant"
|
3
|
-
rescue LoadError
|
4
|
-
raise "The Vagrant ManagedServers plugin must be run within Vagrant."
|
5
|
-
end
|
6
|
-
|
7
|
-
# This is a sanity check to make sure no one is attempting to install
|
8
|
-
# this into an early Vagrant version.
|
9
|
-
if Vagrant::VERSION < "1.
|
10
|
-
raise "The Vagrant ManagedServers plugin is only compatible with Vagrant 1.
|
11
|
-
end
|
12
|
-
|
13
|
-
module VagrantPlugins
|
14
|
-
module ManagedServers
|
15
|
-
class Plugin < Vagrant.plugin("2")
|
16
|
-
name "ManagedServers"
|
17
|
-
description <<-DESC
|
18
|
-
This plugin installs a provider that allows Vagrant to interact with managed servers.
|
19
|
-
DESC
|
20
|
-
|
21
|
-
config(:managed, :provider) do
|
22
|
-
require_relative "config"
|
23
|
-
Config
|
24
|
-
end
|
25
|
-
|
26
|
-
provider(:managed, parallel: true) do
|
27
|
-
# Setup logging and i18n
|
28
|
-
setup_logging
|
29
|
-
setup_i18n
|
30
|
-
|
31
|
-
# Return the provider
|
32
|
-
require_relative "provider"
|
33
|
-
Provider
|
34
|
-
end
|
35
|
-
|
36
|
-
# This initializes the internationalization strings.
|
37
|
-
def self.setup_i18n
|
38
|
-
I18n.load_path << File.expand_path("locales/en.yml", ManagedServers.source_root)
|
39
|
-
I18n.reload!
|
40
|
-
end
|
41
|
-
|
42
|
-
# This sets up our log level to be whatever VAGRANT_LOG is.
|
43
|
-
def self.setup_logging
|
44
|
-
require "log4r"
|
45
|
-
|
46
|
-
level = nil
|
47
|
-
begin
|
48
|
-
level = Log4r.const_get(ENV["VAGRANT_LOG"].upcase)
|
49
|
-
rescue NameError
|
50
|
-
# This means that the logging constant wasn't found,
|
51
|
-
# which is fine. We just keep `level` as `nil`. But
|
52
|
-
# we tell the user.
|
53
|
-
level = nil
|
54
|
-
end
|
55
|
-
|
56
|
-
# Some constants, such as "true" resolve to booleans, so the
|
57
|
-
# above error checking doesn't catch it. This will check to make
|
58
|
-
# sure that the log level is an integer, as Log4r requires.
|
59
|
-
level = nil if !level.is_a?(Integer)
|
60
|
-
|
61
|
-
# Set the logging level on all "vagrant" namespaced
|
62
|
-
# logs as long as we have a valid level.
|
63
|
-
if level
|
64
|
-
logger = Log4r::Logger.new("vagrant_managed_servers")
|
65
|
-
logger.outputters = Log4r::Outputter.stderr
|
66
|
-
logger.level = level
|
67
|
-
logger = nil
|
68
|
-
end
|
69
|
-
end
|
70
|
-
end
|
71
|
-
end
|
72
|
-
end
|
1
|
+
begin
|
2
|
+
require "vagrant"
|
3
|
+
rescue LoadError
|
4
|
+
raise "The Vagrant ManagedServers plugin must be run within Vagrant."
|
5
|
+
end
|
6
|
+
|
7
|
+
# This is a sanity check to make sure no one is attempting to install
|
8
|
+
# this into an early Vagrant version.
|
9
|
+
if Vagrant::VERSION < "1.6.0"
|
10
|
+
raise "The Vagrant ManagedServers plugin is only compatible with Vagrant 1.6+"
|
11
|
+
end
|
12
|
+
|
13
|
+
module VagrantPlugins
|
14
|
+
module ManagedServers
|
15
|
+
class Plugin < Vagrant.plugin("2")
|
16
|
+
name "ManagedServers"
|
17
|
+
description <<-DESC
|
18
|
+
This plugin installs a provider that allows Vagrant to interact with managed servers.
|
19
|
+
DESC
|
20
|
+
|
21
|
+
config(:managed, :provider) do
|
22
|
+
require_relative "config"
|
23
|
+
Config
|
24
|
+
end
|
25
|
+
|
26
|
+
provider(:managed, parallel: true) do
|
27
|
+
# Setup logging and i18n
|
28
|
+
setup_logging
|
29
|
+
setup_i18n
|
30
|
+
|
31
|
+
# Return the provider
|
32
|
+
require_relative "provider"
|
33
|
+
Provider
|
34
|
+
end
|
35
|
+
|
36
|
+
# This initializes the internationalization strings.
|
37
|
+
def self.setup_i18n
|
38
|
+
I18n.load_path << File.expand_path("locales/en.yml", ManagedServers.source_root)
|
39
|
+
I18n.reload!
|
40
|
+
end
|
41
|
+
|
42
|
+
# This sets up our log level to be whatever VAGRANT_LOG is.
|
43
|
+
def self.setup_logging
|
44
|
+
require "log4r"
|
45
|
+
|
46
|
+
level = nil
|
47
|
+
begin
|
48
|
+
level = Log4r.const_get(ENV["VAGRANT_LOG"].upcase)
|
49
|
+
rescue NameError
|
50
|
+
# This means that the logging constant wasn't found,
|
51
|
+
# which is fine. We just keep `level` as `nil`. But
|
52
|
+
# we tell the user.
|
53
|
+
level = nil
|
54
|
+
end
|
55
|
+
|
56
|
+
# Some constants, such as "true" resolve to booleans, so the
|
57
|
+
# above error checking doesn't catch it. This will check to make
|
58
|
+
# sure that the log level is an integer, as Log4r requires.
|
59
|
+
level = nil if !level.is_a?(Integer)
|
60
|
+
|
61
|
+
# Set the logging level on all "vagrant" namespaced
|
62
|
+
# logs as long as we have a valid level.
|
63
|
+
if level
|
64
|
+
logger = Log4r::Logger.new("vagrant_managed_servers")
|
65
|
+
logger.outputters = Log4r::Outputter.stderr
|
66
|
+
logger.level = level
|
67
|
+
logger = nil
|
68
|
+
end
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vagrant-managed-servers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Torben Knerr
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-04-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|