From e0824b83e80d685d21e52398f6533c7fd25db64a Mon Sep 17 00:00:00 2001 From: Paulo Ricardo Motta Gomes Date: Thu, 23 Jan 2014 17:07:16 -0200 Subject: [PATCH 1/2] using options[:mount_options] on volume creation if that option is provided --- recipes/volumes.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/recipes/volumes.rb b/recipes/volumes.rb index efb2d1f..273e1a1 100644 --- a/recipes/volumes.rb +++ b/recipes/volumes.rb @@ -53,7 +53,11 @@ mount mount_point do fstype options[:fstype] device device - options 'noatime,nobootwait' + unless options[:mount_options] + options 'noatime,nobootwait' + else + options options[:mount_options] + end action [:mount, :enable] end From 0ccd46d3703267735db2ee20d21ee8c67fe95f73 Mon Sep 17 00:00:00 2001 From: Paulo Ricardo Motta Gomes Date: Thu, 23 Jan 2014 17:07:38 -0200 Subject: [PATCH 2/2] added pass option on volume creation --- README.md | 2 ++ recipes/volumes.rb | 3 +++ 2 files changed, 5 insertions(+) diff --git a/README.md b/README.md index 1caacd3..3285a46 100644 --- a/README.md +++ b/README.md @@ -79,6 +79,8 @@ Create a 10GB volume with 1000 provisioned iops, format it with XFS, and mount i `mount_options` are optional and will default to `noatime,nobootwait` on all platforms except Amazon linux, where they will default to `noatime`. +`pass` The pass number used by the file system check (fsck) command while creating a file systems table (fstab) entry. Optional property (Default: 2). + ## Credentials Expects a `credentials` databag with an `aws` item that contains `aws_access_key_id` and `aws_secret_access_key`. diff --git a/recipes/volumes.rb b/recipes/volumes.rb index 273e1a1..21ae48e 100644 --- a/recipes/volumes.rb +++ b/recipes/volumes.rb @@ -58,6 +58,9 @@ else options options[:mount_options] end + if options[:pass] + pass options[:pass] + end action [:mount, :enable] end