http://qs321.pair.com?node_id=11122534


in reply to Perl module for automating the modification of config files?

This problem space is called configuration management and there are a number of tools being used for this e.g. Ansible, Salt, Puppet etc.

Rex is the only one implemented in Perl that I know of (not sure how much that matters though).

  • Comment on Re: Perl module for automating the modification of config files?

Replies are listed 'Best First'.
Re^2: Perl module for automating the modification of config files?
by LanX (Saint) on Oct 05, 2020 at 12:26 UTC
    These solutions are meant for mid to large scale remote deployment of fixed versions.

    I suppose the actual management of config files is primarily done with templates° and must - if properly done - be adjusted for every new software version. This pays off when scalability matters.

    But the ability to adjust to an extended config file of a new version for a single installation will be limited, especially if it comes in the OP's shown form of a default cfg where one is supposed to uncomment options.

    In this case

    • storing the old default
    • alarming about diffs
    • adjusting the template manually

    might be the only pragmatic solution to have some efficiency.

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    Wikisyntax for the Monastery

    update

    °) please correct me otherwise!