buluma.ulimit
Ansible Role ulimit
This role sets up ulimit (user limits) on your system.
GitHub | Version | Issues | Pull Requests | Downloads |
---|---|---|---|---|
Example Playbook
Below is an example playbook taken from molecule/default/converge.yml
. This playbook is tested with every update and release.
---
- name: Converge
hosts: all
become: true
gather_facts: false
roles:
- role: buluma.ulimit
ulimit_items:
- limit_item: nofile
domain: root
limit_type: soft
value: 1048576
- limit_item: nproc
domain: root
limit_type: soft
value: 1024
- limit_item: nproc
domain: root
limit_type: hard
value: 2048
The machine needs to be prepared first. In CI, this is done with molecule/default/prepare.yml
:
---
- name: Prepare
hosts: all
become: true
gather_facts: false
roles:
- role: buluma.bootstrap
For more details, see a full explanation and example on how to use these roles.
Role Variables
Default values for variables are set in defaults/main.yml
:
---
# Defaults for ulimit
# Default domain, can be overridden per item.
ulimit_domain: '*'
# Default limit type, can be overridden per item.
ulimit_limit_type: soft
# File to write the limits to.
ulimit_dest: /etc/security/limits.conf
# Should a backup of limits.conf be created on changes?
ulimit_backup: true
Requirements
- Python packages listed in requirements.txt.
State of Used Roles
The roles below are used to prepare the system. You can also prepare your system differently.
Requirement | GitHub | Version |
---|---|---|
buluma.bootstrap |
Context
This role is part of multiple compatible roles. Check out the documentation of these roles for more information.
Here’s an overview of related roles:
Compatibility
This role has been tested on the following container images:
Container | Tags |
---|---|
Amazon | Candidate |
EL | 8 |
Debian | all |
Fedora | all |
opensuse | all |
Ubuntu | all |
The minimum required Ansible version is 2.12, and tests have been conducted on:
- The previous version.
- The current version.
- The development version.
If you find any issues, please report them on GitHub.
Changelog
See the Role History for updates.
License
This role is licensed under Apache-2.0.
Author Information
Created by Shadow Walker.
ansible-galaxy install buluma.ulimit