Manages sysfs in Debian-like systems (using sysfsutils).
sysfsutils
(will be installed)
sysfs_sysfs_d_files
[default:{}
]:/etc/sysfs.d/*
file(s) declarationssysfs_sysfs_d_files.key
: The name of the sysfs configuration file (e.g001-transparent-hugepage.conf
)sysfs_sysfs_d_files.key.{n}.action
[optional]:mode
orowner
, when not specified the new value for specified attribute is setsysfs_sysfs_d_files.key.{n}.attribute
[required]: Name of an attribute, specified as a path without/sys
prefix (e.g.kernel/mm/transparent_hugepage/enabled
)sysfs_sysfs_d_files.key.{n}.value
[required]: Value for the attribute (e.g.never
)
None
---
- hosts: all
roles:
- oefenweb.sysfs
---
- hosts: all
roles:
- oefenweb.sysfs
vars:
sysfs_sysfs_d_files:
000-power-state.conf:
- action: mode
attribute: power/state
value: '0660'
- action: owner
attribute: power/state
value: 'root:vagrant'
001-transparent-hugepage.conf:
- attribute: kernel/mm/transparent_hugepage/enabled
value: never
- attribute: kernel/mm/transparent_hugepage/defrag
value: never
Apache
- Mischa ter Smitten (based on work of Lukasz Szczesny)
Are welcome!