vagrant-lxc 0.6.2 → 0.6.3
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 +10 -0
- data/Gemfile.lock +1 -1
- data/boxes/build-debian-box.sh +1 -1
- data/boxes/common/install-salt-debian +28 -0
- data/lib/vagrant-lxc/action/share_folders.rb +4 -2
- data/lib/vagrant-lxc/driver/cli.rb +2 -2
- data/lib/vagrant-lxc/sudo_wrapper.rb +6 -1
- data/lib/vagrant-lxc/version.rb +1 -1
- data/spec/unit/driver/cli_spec.rb +2 -2
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 990ef5aede9667e2cb3b0abab7eb851da17d7b28
|
4
|
+
data.tar.gz: 969e6045235f3d9e12e942f8ee10244c4c3a5834
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fca22e79ad331aa2e7ae48bd9ccc13c7497b0a79cb83d4aa292ae74492bf70905734b2b564812644b8cf950d54b230b7025b4f50fe4340ea070c0f6d376d2f09
|
7
|
+
data.tar.gz: d2a5421b294892a96bf8a777e35501a3b8a0e1b589bdf076f91982b8783357b79f9223cf1736c700291052c30856b1ab870f71aa3770504f299ff2f820648fc1
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,13 @@
|
|
1
|
+
## [0.6.3](https://github.com/fgrehm/vagrant-lxc/compare/v0.6.2...v0.6.3) (Oct 12, 2013)
|
2
|
+
|
3
|
+
IMPROVEMENTS:
|
4
|
+
|
5
|
+
- Respect Vagrantfile option to disable synced folders [#147](https://github.com/fgrehm/vagrant-lxc/issues/147)
|
6
|
+
|
7
|
+
BUG FIXES:
|
8
|
+
|
9
|
+
- Fix error raised when fetching container's IP with the sudo wrapper disabled [#157](https://github.com/fgrehm/vagrant-lxc/issues/157)
|
10
|
+
|
1
11
|
## [0.6.2](https://github.com/fgrehm/vagrant-lxc/compare/v0.6.1...v0.6.2) (Oct 03, 2013)
|
2
12
|
|
3
13
|
IMPROVEMENTS:
|
data/Gemfile.lock
CHANGED
data/boxes/build-debian-box.sh
CHANGED
@@ -0,0 +1,28 @@
|
|
1
|
+
#!/bin/bash
|
2
|
+
|
3
|
+
set -e
|
4
|
+
|
5
|
+
rootfs=$1
|
6
|
+
|
7
|
+
echo "installing salt"
|
8
|
+
|
9
|
+
if [ $SUITE == "squeeze" ]; then
|
10
|
+
SALT_SOURCE="deb http://debian.saltstack.com/debian squeeze-saltstack main\ndeb http://backports.debian.org/debian-backports squeeze-backports main contrib non-free"
|
11
|
+
elif [ $SUITE == "sid" ]; then
|
12
|
+
SALT_SOURCE="deb http://debian.saltstack.com/debian unstable main"
|
13
|
+
else
|
14
|
+
SALT_SOURCE="deb http://debian.saltstack.com/debian wheezy-saltstack main"
|
15
|
+
fi
|
16
|
+
|
17
|
+
cat > $rootfs/tmp/install-salt << EOF
|
18
|
+
#!/bin/sh
|
19
|
+
echo "$SALT_SOURCE" > /etc/apt/sources.list.d/saltstack.list
|
20
|
+
wget -q -O- "http://debian.saltstack.com/debian-salt-team-joehealy.gpg.key" | apt-key add -
|
21
|
+
apt-get update
|
22
|
+
apt-get install -y salt-minion
|
23
|
+
apt-get clean
|
24
|
+
EOF
|
25
|
+
|
26
|
+
chroot $rootfs sh /tmp/install-salt
|
27
|
+
|
28
|
+
rm -rf $rootfs/tmp/*
|
@@ -13,11 +13,13 @@ module Vagrant
|
|
13
13
|
@app.call env
|
14
14
|
end
|
15
15
|
|
16
|
-
# This method returns an actual list of
|
17
|
-
#
|
16
|
+
# This method returns an actual list of synced folders to create and their
|
17
|
+
# proper path.
|
18
18
|
def shared_folders
|
19
19
|
{}.tap do |result|
|
20
20
|
@env[:machine].config.vm.synced_folders.each do |id, data|
|
21
|
+
# Ignore disabled shared folders
|
22
|
+
next if data[:disabled]
|
21
23
|
# This to prevent overwriting the actual shared folders data
|
22
24
|
result[id] = data.dup
|
23
25
|
end
|
@@ -84,7 +84,7 @@ module Vagrant
|
|
84
84
|
|
85
85
|
if namespaces
|
86
86
|
if supports_attach_with_namespaces?
|
87
|
-
extra = ['--namespaces', namespaces]
|
87
|
+
extra = ['--namespaces', namespaces]
|
88
88
|
else
|
89
89
|
raise LXC::Errors::NamespacesNotSupported
|
90
90
|
end
|
@@ -119,7 +119,7 @@ module Vagrant
|
|
119
119
|
|
120
120
|
def supports_attach_with_namespaces?
|
121
121
|
unless defined?(@supports_attach_with_namespaces)
|
122
|
-
@supports_attach_with_namespaces = run(:attach, '-h',
|
122
|
+
@supports_attach_with_namespaces = run(:attach, '-h', :show_stderr => true).values.join.include?('--namespaces')
|
123
123
|
end
|
124
124
|
|
125
125
|
return @supports_attach_with_namespaces
|
@@ -58,7 +58,12 @@ module Vagrant
|
|
58
58
|
|
59
59
|
# Return the output, making sure to replace any Windows-style
|
60
60
|
# newlines with Unix-style.
|
61
|
-
r.stdout.gsub("\r\n", "\n")
|
61
|
+
stdout = r.stdout.gsub("\r\n", "\n")
|
62
|
+
if opts[:show_stderr]
|
63
|
+
{ :stdout => stdout, :stderr => r.stderr.gsub("\r\n", "\n") }
|
64
|
+
else
|
65
|
+
stdout
|
66
|
+
end
|
62
67
|
end
|
63
68
|
|
64
69
|
def raw(*command, &block)
|
data/lib/vagrant-lxc/version.rb
CHANGED
@@ -146,13 +146,13 @@ describe Vagrant::LXC::Driver::CLI do
|
|
146
146
|
end
|
147
147
|
|
148
148
|
it 'supports a "namespaces" parameter' do
|
149
|
-
subject.stub(:run).with(:attach, '-h',
|
149
|
+
subject.stub(:run).with(:attach, '-h', :show_stderr => true).and_return({:stdout => '', :stderr => '--namespaces'})
|
150
150
|
subject.attach *(command + [{namespaces: ['network', 'mount']}])
|
151
151
|
subject.should have_received(:run).with(:attach, '--name', name, '--namespaces', 'NETWORK|MOUNT', '--', *command)
|
152
152
|
end
|
153
153
|
|
154
154
|
it 'raises a NamespacesNotSupported error if not supported' do
|
155
|
-
subject.stub(:run).with(:attach, '-h',
|
155
|
+
subject.stub(:run).with(:attach, '-h', :show_stderr => true).and_return({:stdout => '', :stderr => 'not supported'})
|
156
156
|
expect {
|
157
157
|
subject.attach *(command + [{namespaces: ['network', 'mount']}])
|
158
158
|
}.to raise_error(Vagrant::LXC::Errors::NamespacesNotSupported)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vagrant-lxc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fabio Rehm
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-10-
|
11
|
+
date: 2013-10-12 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Linux Containers provider for Vagrant
|
14
14
|
email:
|
@@ -37,6 +37,7 @@ files:
|
|
37
37
|
- boxes/common/install-chef
|
38
38
|
- boxes/common/install-puppet
|
39
39
|
- boxes/common/install-salt
|
40
|
+
- boxes/common/install-salt-debian
|
40
41
|
- boxes/common/lxc-template
|
41
42
|
- boxes/common/lxc.conf
|
42
43
|
- boxes/common/metadata.json
|
@@ -142,4 +143,3 @@ test_files:
|
|
142
143
|
- spec/unit/driver_spec.rb
|
143
144
|
- spec/unit/support/unit_example_group.rb
|
144
145
|
- spec/unit_helper.rb
|
145
|
-
has_rdoc:
|