cookbook 'chef_zfs', '= 1.0.0'
chef_zfs (3) Versions 1.0.0 Follow2
Manage ZFS
cookbook 'chef_zfs', '= 1.0.0', :supermarket
knife supermarket install chef_zfs
knife supermarket download chef_zfs
chef_zpool Cookbook
A resource for managing ZFS filesystems. This cookbook is forked from the original zfs cookbook by Martha Greenberg at https://github.com/marthag8/zfs.
Requirements
Platforms
- Ubuntu
- FreeBSD
- Solaris
Chef
- Chef 12.7+
Cookbooks
- none
Resources
zfs
Actions
:create
:upgrade
:destroy
Properties
-
properties
: ZFS properties are set as an Hrray of Hashes to configure the filesystems using the singleproperties
attribute.
Examples
Creating a ZFS Filesytem
zfs "tank/test" do properties [ { mountpoint: '/opt/test' }, { relatime: 'on' }, { compression: 'lz4' } ] action :create end
Upgrading a ZFS to the latest filesystem version:
zfs "tank/test" do action :upgrade end
zfs "tank/test" do properties [ { mountpoint: '/opt/test' }, { relatime: 'on' }, { compression: 'lz4' } ] action [:create, :upgrade] end
Destroying a ZFS Filesystem
zfs "tank/test" do action :destroy end
:sparkles: Note that destroy flags are not directly supported. However, some like the -d
flag can be used by setting the defer_destroy
property on the filesystem prior to desctruction. See the example below.
filesystem = zfs "tank/test" do properties [ { defer_destroy: 'on' } ] action :create only_if "zfs list | grep -q #{self.name}" end zfs filesystem.name do action :destroy end
Maintainers
This cookbook is maintained by Chef's Community Cookbook Engineering team. Our goal is to improve cookbook quality and to aid the community in contributing to cookbooks. To learn more about our team, process, and design goals see our team documentation. To learn more about contributing to cookbooks like this see our contributing documentation, or if you have general questions about this cookbook come chat with us in #cookbok-engineering on the Chef Community Slack
License
Copyright: 2012-2017, Martha Greenberg Copyright: 2017, Chef Software, Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Dependent cookbooks
This cookbook has no specified dependencies.
Contingent cookbooks
There are no cookbooks that are contingent upon this one.
chef_zfs Cookbook CHANGELOG
This file is used to list changes made in each version of the chef_zfs cookbook.
1.0.0 (2017-11-13)
- This cookbook has been forked from the zfs cookbook originally written by Martha Greenberg
- Rewrote the existing LWRP as a custom resource. This requires Chef 12.7 or later
- Updated testing with additional platforms and replaced Rake with Delivery local mode
- Expanded the readme documentation for the resource and requirments
- Resolved Foodcritic and Cookstyle warnings
Collaborator Number Metric
1.0.0 passed this metric
Contributing File Metric
1.0.0 passed this metric
Foodcritic Metric
1.0.0 passed this metric
License Metric
1.0.0 passed this metric
No Binaries Metric
1.0.0 passed this metric
Testing File Metric
1.0.0 passed this metric
Version Tag Metric
1.0.0 passed this metric
1.0.0 passed this metric
1.0.0 passed this metric
Foodcritic Metric
1.0.0 passed this metric
License Metric
1.0.0 passed this metric
No Binaries Metric
1.0.0 passed this metric
Testing File Metric
1.0.0 passed this metric
Version Tag Metric
1.0.0 passed this metric
1.0.0 passed this metric
1.0.0 passed this metric
No Binaries Metric
1.0.0 passed this metric
Testing File Metric
1.0.0 passed this metric
Version Tag Metric
1.0.0 passed this metric
1.0.0 passed this metric
1.0.0 passed this metric
Version Tag Metric
1.0.0 passed this metric
1.0.0 passed this metric