NAME

Setup - Specification for setup module

VERSION

version 1.0.1

SPECIFICATION VERSION

1.0

SPECIFICATION

This is a specification for setup modules. Setup modules are normal Perl modules that live under the Setup:: namespace and contain setup functions. Setup functions are normal Perl subroutines, typically named with setup_ prefix (like setup_file, setup_unix_user, etc.) They are typically used for, well, setting up stuffs, like software installation, system setup, or configuration management.

Setup functions must support these features: idempotency (useful for configuration management), transaction, undo/redo (useful for uninstallation of software), and dry-run/simulation mode (useful for debugging).

Setup functions must follow Rinci specification, since Rinci already specifies all of these functionalities. Setup functions should also be written with the helper Perinci::Sub::Undoable, to make all Setup functions more consistent.

As an additional note, aside from idempotency, the functions must also check for initial/original condition. There could be various state changes between the time of do and undo; a file can be deleted or modified by other processes. The undo must be flexible enough so it can reverse whatever state changes the previous do phase did whenever it can, but not disrupt other processes' changes.

SEE ALSO

Rinci (specifically Rinci::function::Undo and Rinci::function::Transaction).

Riap (specifically Riap::Transaction).

AUTHOR

Steven Haryanto <stevenharyanto@gmail.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2012 by Steven Haryanto.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.