vagrant-bindfs 0.2.3 → 0.2.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -15
- data/README.md +17 -11
- data/lib/vagrant-bindfs/bind.rb +10 -3
- data/lib/vagrant-bindfs/version.rb +1 -1
- metadata +33 -27
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
|
-
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
metadata.gz: !binary |-
|
9
|
-
NzkxNDcwMjZmY2QzNGQwNmEwZmMxYzFkNmZkN2VkYjliYmQ1NTE1OWZmMjBi
|
10
|
-
NzUzZDhhOWIzMzM3OGFkZDMwOTg4MjM3Yzg3ZTYxNTM3NjFjZDM5ZjY0ZmE2
|
11
|
-
MjU0YWU2ODMzZjBhNTdmYWY0MDYxNzFkNzIwNTEwYzQ0OGUyMzA=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
ZDIzNjgyMDJlYmU1ZmQ1MzgwODRiYTU5MGYzMzhjYjk5MTVhNWNmZGJjYTg3
|
14
|
-
YWUwYjYxZjc3MjVjYmMxOWVmYzBiYjkxNjViN2U4NzE1MGY1MTNmNDg2NmQ1
|
15
|
-
Yjk0N2I1N2YyOTMwYWU3M2JkNDdiOGYyNTkzMDJmNjUzZjBkMjU=
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: f3a91ef3c7189be732845454b9099c48f42f4b33
|
4
|
+
data.tar.gz: 09b853dcb880f59066f3571b0a886c968cb22bd1
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: ae49587125019c1779a3d03302410b994327663f7ef09430e1926ae5959e82e0febe2a46ea99b8dad6893243015239f00016c0802b460bbb494e1dec8fcc6311
|
7
|
+
data.tar.gz: 16b33f5b3ccf30518f1f9405346e5994402134d58955800d757db06e710f293f66505fdb0a401e7b49043854f50824b3ad3a31e56fda679fb3081039ea6d3360
|
data/README.md
CHANGED
@@ -1,16 +1,21 @@
|
|
1
1
|
# vagrant-bindfs
|
2
2
|
|
3
|
-
A Vagrant plugin to automate [bindfs](http://
|
3
|
+
A Vagrant plugin to automate [bindfs](http://bindfs.org/) mount in the VM.
|
4
4
|
This allow you to change owner, group and permissions on files and, for example, work around NFS share permissions issues.
|
5
5
|
|
6
6
|
|
7
7
|
## Some Background: Why `vagrant-bindfs`
|
8
8
|
|
9
|
-
The default vagrant provider is [virtualbox](https://www.virtualbox.org/).
|
9
|
+
The default vagrant provider is [virtualbox](https://www.virtualbox.org/).
|
10
|
+
It's free, and it works well, but it has some [performance problems](http://snippets.aktagon.com/snippets/609-Slow-IO-performance-with-Vagrant-and-VirtualBox-).
|
10
11
|
|
11
|
-
People often recommend switching to [vagrant's VMWare-fusion provider](http://www.vagrantup.com/vmware).
|
12
|
+
People often recommend switching to [vagrant's VMWare-fusion provider](http://www.vagrantup.com/vmware).
|
13
|
+
This reportedly has better performance, but shares with symlinks [won't work](http://communities.vmware.com/thread/428199?start=0&tstart=0).
|
14
|
+
You also have to buy both the plugin and VMWare-fusion.
|
12
15
|
|
13
|
-
The final recommendation, at least on Linux/OSX hosts, is to [use nfs](http://docs.vagrantup.com/v2/synced-folders/nfs.html).
|
16
|
+
The final recommendation, at least on Linux/OSX hosts, is to [use nfs](http://docs.vagrantup.com/v2/synced-folders/nfs.html).
|
17
|
+
However, an NFS mount has the same numeric permissions in the guest as in the host.
|
18
|
+
If you're on OSX, for instance, a folder owned by the default OSX user will appear to be [owned by `501:20`](https://groups.google.com/forum/?fromgroups#!topic/vagrant-up/qXXJ-AQuKQM) in the guest.
|
14
19
|
|
15
20
|
This is where `vagrant-bindfs` comes in!
|
16
21
|
|
@@ -23,13 +28,13 @@ _Note that `map_uid` and `map_gid` NFS options can be used to set the identity u
|
|
23
28
|
|
24
29
|
## Installation
|
25
30
|
|
26
|
-
Vagrant-bindfs is distributed as a Ruby gem.
|
31
|
+
Vagrant-bindfs is distributed as a Ruby gem.
|
27
32
|
You can install it as any other Vagrant plugin with `vagrant plugin install vagrant-bindfs`.
|
28
33
|
|
29
34
|
|
30
35
|
## Usage
|
31
36
|
|
32
|
-
In your `Vagrantfile`, use `config.bindfs.bind_folder` to configure folders that will be binded on VM startup.
|
37
|
+
In your `Vagrantfile`, use `config.bindfs.bind_folder` to configure folders that will be binded on VM startup.
|
33
38
|
The format is:
|
34
39
|
|
35
40
|
```ruby
|
@@ -72,6 +77,7 @@ The format is:
|
|
72
77
|
- `:group` (defaults to 'vagrant')
|
73
78
|
- `:perms` (defaults to 'u=rwX:g=rD:o=rD')
|
74
79
|
- `:mirror`
|
80
|
+
- `:o`
|
75
81
|
- `:'mirror-only'`
|
76
82
|
- `:'create-for-user'`
|
77
83
|
- `:'create-for-group'`
|
@@ -99,26 +105,26 @@ The format is:
|
|
99
105
|
|
100
106
|
You can overwrite default options _via_ `config.bindfs.default_options`.
|
101
107
|
|
102
|
-
See [bindfs man page](http://
|
108
|
+
See [bindfs man page](http://bindfs.org/docs/bindfs.1.html) for details.
|
103
109
|
|
104
|
-
vagrant-bindfs does not check compatibility between given arguments but warn you when a binding command fail or if bindfs is not installed on your virtual machine.
|
110
|
+
vagrant-bindfs does not check compatibility between given arguments but warn you when a binding command fail or if bindfs is not installed on your virtual machine.
|
105
111
|
On Debian systems, it will try to install bindfs automatically.
|
106
112
|
|
107
113
|
|
108
114
|
## Contributing
|
109
115
|
|
110
|
-
If you find this plugin useful, we could use a few enhancements!
|
116
|
+
If you find this plugin useful, we could use a few enhancements!
|
111
117
|
In particular, capabilities files for installing vagrant-bindfs on systems other than Debian would be useful. We could also use some specs…
|
112
118
|
|
113
119
|
|
114
120
|
### How to Test Changes
|
115
121
|
|
116
|
-
If you've made changes to this plugin, you can easily test it locally in vagrant.
|
122
|
+
If you've made changes to this plugin, you can easily test it locally in vagrant.
|
117
123
|
From the root of the repo, do:
|
118
124
|
|
119
125
|
- `bundle install`
|
120
126
|
- `rake build`
|
121
127
|
- `bundle exec vagrant up`
|
122
128
|
|
123
|
-
This will spin up a default Debian VM and try to bindfs-mount some shares in it.
|
129
|
+
This will spin up a default Debian VM and try to bindfs-mount some shares in it.
|
124
130
|
Feel free to modify the included `Vagrantfile` to add additional test cases.
|
data/lib/vagrant-bindfs/bind.rb
CHANGED
@@ -2,6 +2,7 @@ module VagrantPlugins
|
|
2
2
|
module Bindfs
|
3
3
|
module Action
|
4
4
|
class Bind
|
5
|
+
|
5
6
|
# Options
|
6
7
|
@@options = {
|
7
8
|
:owner => 'vagrant',
|
@@ -13,7 +14,12 @@ module VagrantPlugins
|
|
13
14
|
:'create-for-group' => nil,
|
14
15
|
:'create-with-perms' => nil,
|
15
16
|
}
|
16
|
-
|
17
|
+
|
18
|
+
# Shorthands
|
19
|
+
@@shorthands = {
|
20
|
+
:o => nil,
|
21
|
+
}
|
22
|
+
|
17
23
|
# Flags
|
18
24
|
@@flags = {
|
19
25
|
:'no-allow-other' => false,
|
@@ -57,7 +63,7 @@ module VagrantPlugins
|
|
57
63
|
end
|
58
64
|
|
59
65
|
def default_options
|
60
|
-
@@options.merge(@@flags).merge(@machine.config.bindfs.default_options)
|
66
|
+
@@options.merge(@@shorthands).merge(@@flags).merge(@machine.config.bindfs.default_options)
|
61
67
|
end
|
62
68
|
|
63
69
|
def normalize_options opts
|
@@ -67,8 +73,9 @@ module VagrantPlugins
|
|
67
73
|
|
68
74
|
args = []
|
69
75
|
opts.each do |key, value|
|
70
|
-
args << "--#{key.to_s}"
|
76
|
+
args << "--#{key.to_s}" if @@flags.key?(key) and !!value
|
71
77
|
args << "--#{key.to_s}=#{value}" if @@options.key?(key) and !value.nil?
|
78
|
+
args << "-#{key.to_s} #{value}" if @@shorthands.key?(key) and !value.nil?
|
72
79
|
end
|
73
80
|
|
74
81
|
[ source, dest, " #{args.join(" ")}" ]
|
metadata
CHANGED
@@ -1,26 +1,32 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: vagrant-bindfs
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.2.4
|
5
5
|
platform: ruby
|
6
|
-
authors:
|
7
|
-
-
|
6
|
+
authors:
|
7
|
+
- "Ga\xC3\xABl-Ian Havard"
|
8
8
|
- Igor Serebryany
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
|
12
|
+
|
13
|
+
date: 2014-01-04 00:00:00 Z
|
13
14
|
dependencies: []
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
email:
|
15
|
+
|
16
|
+
description: A Vagrant plugin to automate bindfs mount in the VM. This allow you to change owner, group and permissions on files and, for example, work around NFS share permissions issues.
|
17
|
+
email:
|
18
18
|
- gaelian.havard@gmail.com
|
19
19
|
- igor.serebryany@airbnb.com
|
20
20
|
executables: []
|
21
|
+
|
21
22
|
extensions: []
|
23
|
+
|
22
24
|
extra_rdoc_files: []
|
23
|
-
|
25
|
+
|
26
|
+
files:
|
27
|
+
- MIT-LICENSE
|
28
|
+
- README.md
|
29
|
+
- lib/vagrant-bindfs.rb
|
24
30
|
- lib/vagrant-bindfs/bind.rb
|
25
31
|
- lib/vagrant-bindfs/cap/debian/bindfs_install.rb
|
26
32
|
- lib/vagrant-bindfs/cap/linux/bindfs_installed.rb
|
@@ -28,32 +34,32 @@ files:
|
|
28
34
|
- lib/vagrant-bindfs/errors.rb
|
29
35
|
- lib/vagrant-bindfs/plugin.rb
|
30
36
|
- lib/vagrant-bindfs/version.rb
|
31
|
-
- lib/vagrant-bindfs.rb
|
32
37
|
- locales/en.yml
|
33
|
-
- README.md
|
34
|
-
- MIT-LICENSE
|
35
38
|
homepage: https://github.com/gael-ian/vagrant-bindfs
|
36
|
-
licenses:
|
39
|
+
licenses:
|
37
40
|
- MIT
|
38
41
|
metadata: {}
|
42
|
+
|
39
43
|
post_install_message:
|
40
44
|
rdoc_options: []
|
41
|
-
|
45
|
+
|
46
|
+
require_paths:
|
42
47
|
- lib
|
43
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
-
|
46
|
-
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
version: '0'
|
48
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
49
|
+
requirements:
|
50
|
+
- &id001
|
51
|
+
- ">="
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: "0"
|
54
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
55
|
+
requirements:
|
56
|
+
- *id001
|
53
57
|
requirements: []
|
58
|
+
|
54
59
|
rubyforge_project:
|
55
|
-
rubygems_version: 2.0
|
60
|
+
rubygems_version: 2.2.0
|
56
61
|
signing_key:
|
57
62
|
specification_version: 4
|
58
63
|
summary: A Vagrant plugin to automate bindfs mount in the VM
|
59
64
|
test_files: []
|
65
|
+
|