Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms

Select Status

RSS

ulimit (15) Versions 0.4.0

Resources for manaing ulimits

Policyfile
Berkshelf
Knife
cookbook 'ulimit', '= 0.4.0', :supermarket
cookbook 'ulimit', '= 0.4.0'
knife supermarket install ulimit
knife supermarket download ulimit
README
Dependencies
Changelog
Quality 57%

Description

This is a short-and-simple cookbook to provide a user_ulimit resource for overriding various ulimit settings. It places configured templates into /etc/security/limits.d/, named for the user the ulimit applies to.

It also provides a helper recipe (default.rb) for allowing ulimit overrides with the 'su' command on Ubuntu, which is disabled by default for some reason.

Finally, it also supplies a more advanced ulimit_domain resource, allowing you to configure a complex set of rules beyond those supported by the definition.

Requirements

Add to your repo, then depend upon this cookbook from wherever you need to override ulimits. (If you're on Ubuntu, you'll also need to add recipe[ulimit] to your runlist, or the files created by this cookbook will be ignored.)

Attributes

  • node['ulimit']['pam_su_template_cookbook'] - Defaults to nil (current cookbook). Determines what cookbook the su pam.d template is taken from
  • node['ulimit']['users'] - Defaults to empty Mash. List of users with their limits, as below.

Usage

Consume the user_ulimit resource like so:

user_ulimit "tomcat" do
  filehandle_limit 8192 # optional
  filehandle_soft_limit 8192 # optional; not used if filehandle_limit is set)
  filehandle_hard_limit 8192 # optional; not used if filehandle_limit is set)
  process_limit 61504 # optional
  process_soft_limit 61504 # optional; not used if process_limit is set)
  process_hard_limit 61504 # optional; not used if process_limit is set)
  memory_limit 1024 # optional
  core_limit 2048 # optional
  core_soft_limit 1024 # optional
  core_hard_limit 'unlimited' # optional
  stack_soft_limit 2048 # optional
  stack_hard_limit 2048 # optional
end

You can also define limits using attributes on roles or nodes:

"default_attributes": {
   "ulimit": {
      "users": {
         "tomcat": {
            "filehandle_limit": 8193,
               "process_limit": 61504
             },
            "hbase": {
               "filehandle_limit": 32768
             }
       }
    }
 }

To specify a change for all users change specify a wildcard like so user_ulimit "*"

Domain LWRP

Note: The ulimit_domain resource creates files named after the domain with no modifiers by default. To override this behavior, specify the filename parameter to the resource.

ulimit_domain 'my_user' do
  rule do
    item :nofile
    type :hard
    value 10000
  end
  rule do
    item :nofile
    type :soft
    value 5000
  end
end

Dependent cookbooks

This cookbook has no specified dependencies.

Contingent cookbooks

aerospike Applicable Versions
apache_hadoop Applicable Versions
apache_zookeeper Applicable Versions
cassandra-dse Applicable Versions
cerner_kafka Applicable Versions
cerner_splunk Applicable Versions
cerner_tomcat Applicable Versions
clickhouse Applicable Versions
common_linux Applicable Versions
cq Applicable Versions
elastic Applicable Versions
et_mesos Applicable Versions
gatling Applicable Versions
hadoop Applicable Versions
hipsnip-mongodb Applicable Versions
hopsworks Applicable Versions
hypertable Applicable Versions
icinga2 Applicable Versions
javadeploy Applicable Versions
kafka-cluster Applicable Versions
nodestack Applicable Versions
redis-omnibus Applicable Versions
redisio Applicable Versions
resin Applicable Versions
riak Applicable Versions
riak-cs Applicable Versions
solrcloud Applicable Versions
stack-base Applicable Versions
thumbor_ng Applicable Versions
trafficserver Applicable Versions
vitess Applicable Versions

CHANGELOG for ulimit

This file is used to list changes made in each version of ulimit.

0.3.2

0.3.1

0.3.0

0.2.0

  • Support specifying users via attributes (as long as your runlist includes the ulimit::default recipe). Thanks to Dmytro Shteflyuk (https://github.com/kpumuk)

0.1.5

0.1.4:

0.1.3:

  • Adds node attribute node['ulimit']['pam_su_template_cookbook'] to allow users to provide a su pam.d template from another cookbook

0.1.2:

0.1.0:

  • Initial release of ulimit

Check the Markdown Syntax Guide for help with Markdown.

The Github Flavored Markdown page describes the differences between markdown on github and standard markdown.

Collaborator Number Metric
            

0.4.0 failed this metric

Failure: Cookbook has 1 collaborators. A cookbook must have at least 2 collaborators to pass this metric.

Contributing File Metric
            

0.4.0 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file

Foodcritic Metric
            

0.4.0 passed this metric

License Metric
            

0.4.0 passed this metric

No Binaries Metric
            

0.4.0 passed this metric

Testing File Metric
            

0.4.0 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file

Version Tag Metric
            

0.4.0 passed this metric