def enable_module(module):
    """
    Enable an Apache module.

    This creates a symbolic link from ``/etc/apache2/mods-available/``
    into ``/etc/apache2/mods-enabled/``.

    This does not cause Apache to reload its configuration.

    ::

        import fabtools

        fabtools.apache.enable_module('rewrite')
        fabtools.service.reload('apache2')

    .. seealso:: :py:func:`fabtools.require.apache.module_enabled`
    """
    if not is_module_enabled(module):
        run_as_root('a2enmod %s' % module)
dataset/ETHPy150Open ronnix/fabtools/fabtools/apache.py/enable_module/original