wip
This commit is contained in:
parent
12268daad6
commit
ce4890e108
4 changed files with 21 additions and 0 deletions
3
bundles/modprobe/files/modprobe.conf
Normal file
3
bundles/modprobe/files/modprobe.conf
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
% for key, value in sorted(options.items()):
|
||||||
|
options ${module} ${key}=${value}
|
||||||
|
% endfor
|
14
bundles/modprobe/items.py
Normal file
14
bundles/modprobe/items.py
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
for module, options in node.metadata.get('modprobe').items():
|
||||||
|
if not options:
|
||||||
|
continue
|
||||||
|
|
||||||
|
files['/etc/modprobe.d'] = {
|
||||||
|
'source': 'modprobe.conf',
|
||||||
|
'content_type': 'mako',
|
||||||
|
'context': {
|
||||||
|
'module': module,
|
||||||
|
'options': options,
|
||||||
|
},
|
||||||
|
'mode': '0644',
|
||||||
|
}
|
||||||
|
|
3
bundles/modprobe/metadata.py
Normal file
3
bundles/modprobe/metadata.py
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
defaults = {
|
||||||
|
'modprobe': {}
|
||||||
|
}
|
|
@ -4,6 +4,7 @@
|
||||||
],
|
],
|
||||||
'bundles': [
|
'bundles': [
|
||||||
'apt',
|
'apt',
|
||||||
|
# 'modprobe',
|
||||||
],
|
],
|
||||||
'metadata': {
|
'metadata': {
|
||||||
'apt': {
|
'apt': {
|
||||||
|
|
Loading…
Reference in a new issue