voxpupuli / puppet-kmod

manage kernel module with puppet
Apache License 2.0
17 stars 63 forks source link

Enhancement: add structured fact containing list of modules #33

Closed faxm0dem closed 2 years ago

faxm0dem commented 9 years ago

I already wrote something similar if you could have a look and tell me if you'd accept a PR in this regard. Proposed format (structured fact):

☠ facter -p kmod
["libata","sg","e1000", ... ]

Or

☠ facter -p kmod
{"nfs"=>{"size"=>188136,"used_by"=>[]},"nfs_acl"=>{"size"=>12511,"used_by"=>["nfsd"]},...}
jhoblitt commented 9 years ago

I am also desiring a fact for all loaded modules. @faxm0dem's second example seems about right as it would generally be more convenient to test if a module is loaded via a hash lookup rather than terating across a list.

faxm0dem commented 9 years ago

Then again we could provide functions that would abstract this fact e.g. kmod_is_loaded('openafs')

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

faxm0dem commented 3 years ago

wow time moves too fast

kenyon commented 2 years ago

Looks like #44 should have closed this, so closing it now.