Coder Social home page Coder Social logo

puppet-kmod's Introduction

Kmod Puppet module

Puppet Forge Version Puppet Forge Downloads Build Status Puppet Forge Endorsement Gemnasium By Camptocamp

Description

This module provides definitions to manipulate modprobe.conf (5) stanzas:

  • kmod::alias
  • kmod::install
  • kmod::blacklist

It depends on Augeas with the modprobe lens.

Usage

This module has five main defined types:

  • kmod::load
  • kmod::alias
  • kmod::option
  • kmod::install
  • kmod::blacklist

kmod::load

Loads a module using modprobe and manages persistent modules in /etc/sysconfig/modules

  kmod::load { 'mymodule': }

kmod::alias

Adds an alias to modprobe.conf, by default /etc/modprobe.d/<name>.conf is assumed for a filename.

  kmod::alias { 'bond0':
    modulename => 'bonding',
  }

Params:

  • modulename: Name of the module to alias
  • aliasname: Name of the alias (defaults to the resource title)
  • file: File to write to (see above default)

kmod::option

Adds an option to modprobe.conf

  kmod::option { 'bond0 mode':
    module  => 'bond0',
    option  => 'mode',
    value   => '1',
  }

  kmod::option { 'bond0':
    option => 'mode',
    value  => '1',
  }

Params:

  • option: Name of the parameter to add
  • value: Value of the parameter
  • module: Name of the module (if ommited, the resource title is used)
  • file: File to write to (defaults to /etc/modprobe.d/<module name>.conf)

kmod::blacklist

Manages modprobe blacklist entries. Blacklist entries prevents module aliases from being used, but would not prevent the module from being loaded. To prevent a module from being loaded use kmod::install

  kmod::blacklist { 'foo': }

Params:

  • file: File to write to, defaults to /etc/modprobe.d/blacklist.conf

kmod::install

Manage modprobe install entries

   kmod::install { 'pcspkr': }

If you want to ensure that module can't be loaded at all you can do the following:

   kmod::install { 'dccp': command => '/bin/false' }

Params:

  • file: File to write to (defaults to /etc/modprobe.d/<module name>.conf)
  • command: (optional) command associated with the install, defaults to /bin/true

Contributing

Please report bugs and feature request using GitHub issue tracker.

For pull requests, it is very much appreciated to check your Puppet manifest with puppet-lint to follow the recommended Puppet style guidelines from the Puppet Labs style guide.

puppet-kmod's People

Contributors

adrienthebo avatar bobtfish avatar buzzdeee avatar ckaenzig avatar crayfishx avatar ggeldenhuis avatar mcanevet avatar raphink avatar saimonn avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.