cookbook 'smbfs', '= 0.2.0'
smbfs (2) Versions 0.2.0 Follow3
Installs/Configures smbfs and adds mount points according to data driven pattern
cookbook 'smbfs', '= 0.2.0', :supermarket
knife supermarket install smbfs
knife supermarket download smbfs
Description
A recipe that installs smbfs on linux hosts. It also includes a resource for mounting cifs shares and an attribute driven recipe managing smbfs mounts.
Requirements
Tested on Ubuntu 11.
Attributes
-
node['smbfs']['mounts']
- A map that describes zero or more cifs mounts. Used to drive theattribtue_driven
recipe.
Usage
There are two recipes provided:
-
smbfs::default
- Install the smbfs package. -
smbfs::attribute_driven
- Invokes thesmbfs::default
recipe and then interprets thenode['smbfs']['mounts']
attribtue and defines the resources for the mouts.
Resources
smbfs_mount
The smbfs_mount
resource helps define a mount for a cifs share.
- path: the path on which to mout the share. This is the name of the resource.
- cifs_path: The url for cifs mount.
- username: The username if authenticated access required to cifs share. Defaults to nil.
- password: The password. Must be present iff username is present. Defaults to nil.
- option: Arbitrary key value pairs passed to mount.
The simplest example for mounting a share;
smbfs_mount '/mnt' do
cifs_path '//san01.example.org/myshare$/Some/Path'
username 'MyUser',
password 'MyPass',
options {'rw' => nil}
end
Attribute Driven Recipe
The simplest example for mounting a share;
node['smbfs']['mounts']['/mnt'] =
{
'cifs_path' => '//san01.example.org/myshare$/Some/Path',
'username' => 'MyUser',
'password' => 'MyPass',
'options' =>
{
'rw' => nil
}
}
include_recipe 'smbfs::attribute_driven'
Dependent cookbooks
This cookbook has no specified dependencies.
Contingent cookbooks
There are no cookbooks that are contingent upon this one.