Resource Type: fm_replace

Defined in:
lib/puppet/type/fm_replace.rb
Providers:
ruby

Overview

Replace one instance of /regex/ in a text file with data and remove all other instances

Properties

  • ensure (defaults to: present)

    Add or remove the requested lines from the file

    Supported values:
    • present
    • absent

Parameters

  • data

    Lines to add to the file - accepts string or array. If n present newlines will be inserted

  • match (defaults to: false)

    If specified, remove all instances of /match/, and insert one line data if ensure=>present

  • path

    The file to operate on - you can only prepend once to any given file