layman - Manage Gentoo overlays

New in version 1.6.


  • Uses Layman to manage an additional repositories for the Portage package manager on Gentoo Linux. Please note that Layman must be installed on a managed node prior using this module.

Requirements (on host that executes module)

  • python >= 2.6
  • layman python module


parameter required default choices comments
An URL of the alternative overlays list that defines the overlay to install. This list will be fetched and saved under ${overlay_defs}/${name}.xml), where overlay_defs is readed from the Layman's configuration.
The overlay id to install, synchronize, or uninstall. Use 'ALL' to sync all of the installed overlays (can be used only when state=updated).
no present
  • present
  • absent
  • updated
Whether to install (present), sync (updated), or uninstall (absent) the overlay.
(added in 1.9.3)
no yes
  • yes
  • no
If no, SSL certificates will not be validated. This should only be set to no when no other option exists. Prior to 1.9.3 the code defaulted to no.


# Install the overlay 'mozilla' which is on the central overlays list.
- layman:
    name: mozilla

# Install the overlay 'cvut' from the specified alternative list.
- layman:
    name: cvut
    list_url: ''

# Update (sync) the overlay 'cvut', or install if not installed yet.
- layman:
    name: cvut
    list_url: ''
    state: updated

# Update (sync) all of the installed overlays.
- layman:
    name: ALL
    state: updated

# Uninstall the overlay 'cvut'.
- layman:
    name: cvut
    state: absent


This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.

For help in developing on modules, should you be so inclined, please read Community Information & Contributing, Testing Ansible and Developing Modules.