Saravanan666/pypi-org huggingface dataset:
Package: ansible-doc-extractor
This package contains code for Ansible collection documentation extractor. Its
main audience are Ansible collection maintainers that would like to publish
API docs in the HTML form without having to manually copy the data already
present in the module’s metadata.QuickstartDocumentation extractor is published onPyPIand we can install it usingpip:$ pip install ansible-doc-extractor  # If we already have ansible installed
$ pip install ansible-doc-extractor[ansible]  # To also install ansible
$ pip install ansible-doc-extractor[base]  # To also install ansible-base
$ pip install ansible-doc-extractor[core]  # To also install ansible-coreIf the previous command did not fail, we are ready to start extracting the
documentation:$ ansible-doc-extractor \
    /tmp/output-folder \
    ~/.ansible/collections/ansible_collections/my/col/plugins/modules/*.pyThis will extract the documentation from modules inmy.colcollection and
place resulting rst files into/tmp/output-folder.NoteAlways extract documentation from installed collection. Documentation
fragment loader fails to combine various parts of the documentation
otherwise.RST and Markdown supportBy defaultansible-doc-extractorwill output files in .rst format using the built-in Jinja2 template for rst. Pass the--markdownflag to output files in markdown.Custom templateansible-doc-extractorsupports a custom Jinja2 template file via--template. The following variables
are sent to the template:Variable nameTypeDescriptionModule’s documentation keyshort_descriptionstrShort description of a module.short_descriptiondescriptionstr / listLonger description of a module, type depends on the module’sdescriptiontype.descriptionrequirementslistRequirements needed on the host that executes this module.requirementsoptionsdictAll module options, often called parameters or arguments.optionsnoteslistModule’s additional notes.notesseealsolistDetails of any important information that doesn’t fit in one of the above sections.seealsodeprecatedstrMarks modules that will be removed in future releasesdeprecatedauthorstr / listAuthor of the module, type can vary depending on how many authors module has.authormetadatadictThis section provides information about the moduleRefers to ANSIBLE_METADATA block in the module.examplesstrCode examplesRefers to EXAMPLES block in the module.returndocsdictThis section documents the information the module returns.Refers to RETURN block in the module.The output files will use the same file extension as the custom template file.You can always refer to thedefault Jinja2 template for rstand thedefault Jinja2 template for markdown.Development setupGetting development environment up and running is relatively simple:$ python3 -m venv venv
$ . venv/bin/activate
(venv) $ pip install -e .To test the extractor, we can run:$ ansible-doc-extractor
Package: ansible-docgenerator
# Ansible-DocGenA python utility for generating Ansible README.md files for roles[![Build Status](https://travis-ci.org/toast38coza/Ansible-DocGen.svg?branch=master)](https://travis-ci.org/toast38coza/Ansible-DocGen)* Ansible-DocGen is tested in `python3`## Installation### PIPpip install ansible-docgeneration**Note if you installed it from pip, you will need to use it like so from the command line:**python -m docgen### From Source```git clone git@github.com:toast38coza/Ansible-DocGen.gitcd Ansible-DocGenvirtualenv-3.4 env -p python3source env/bin/activatepip install -r requirements.txt```## Usage```Usage: docgen.py [OPTIONS]# Basic usage:python docgen.py#Specify a path to a role:python docgen.py --path=/path/to/ansible/role#Specify a path to a role, and output the result to a file:python docgen.py --path=/path/to/ansible/role > /path/to/ansible/role/README.md```**Options:*** `--path`  Path to your role (defaults to current directory)* `--help`       Show this message and exit.## Test.. coming soon## Example output:A role for settings up a django application* **Required ansible version:** >= 1.2## Required variables:| Parameter    | Example  | Comment  ||--------------|----------|----------||`django_app_name`|`polls`|The name of your application. Typcially this will be the name of the folder containing your settings.py file|## Optional variables:| Parameter    | Default ||--------------|----------||`django_settings_directory_path`|`{{django_app_path}}/{{django_project_name}}`||`django_gunicorn_workers`|`2`||`django_venv_path`|`/srv/venvs/{{django_app_name}}`||`django_media_path`|`/srv/{{django_app_name}}/media`||`django_http_port`|`8000`||`manage_commands`|`['collectstatic', 'syncdb', 'migrate']`||`django_settings_vars`|`[]`||`django_static_path`|`/srv/{{django_app_name}}/static`||`django_log_path`|`/var/log/{{django_app_name}}`||`django_requirements_location`|`{{django_app_path}}/requirements.txt`||`django_env_vars`|`[]`||`django_version`|`1.8`||`django_app_path`|`/var/www/{{django_app_name}}`||`django_github_version`|`master`|### Basic usage```- hosts: allvars:- django_app_name: pollsroles:- { role: django, tags: django }```### TODO* TODO: use pex to package virtualenv* Unit testing* Travis CI* Better error handling
Package: ansible-doctor
ansible-doctorAnnotation based documentation for your Ansible rolesThis project is based on the idea (and at some parts on the code) ofansible-autodocby Andres Bott so credits goes to him for his work.ansible-doctoris a simple annotation like documentation generator based on Jinja2 templates. Whileansible-doctorcomes with a default template calledreadme, it is also possible to write custom templates to customize the output or render the data to other formats like HTML or XML as well.ansible-doctoris designed to work within a CI pipeline to complete the existing testing and deployment workflow. Releases are available as Python Packages onGitHuborPyPIand as Docker Image onDocker Hub.The full documentation is available athttps://ansible-doctor.geekdocs.de.ContributorsSpecial thanks to allcontributors. If you would like to contribute,
please see theinstructions.LicenseThis project is licensed under the GPL-3.0 License - see theLICENSEfile for details.
Package: ansible-dotdiff
Nested structure diff library with dot-path notation for Ansible.DescriptionThis package is built to plug into Ansible’s module_utils, which doesn’t require
it to be installed on managed remote hosts, only the controller. It will be picked
up by Ansiballz, which zips a module’s dependencies and ships it over SSH.
The library is kept small to keep the footprint down.UsageBy design, the algorithm will ignore any keys that are omitted on the right (the target),
to allow an API endpoint to choose plausible defaults. For example, an API client
implementing this library will diff the desired state with a JSON REST resource
to predict whether or not a REST call needs to occur for the user’s changes to be applied.from ansible.module_utils.dotdiff import dotdifforig = { ‘one’: ‘one’,‘two’: ‘two’ }dest = { ‘one’: ‘another’,‘three’: ‘three’ }dotdiff(orig, dest)dotdiff() yields a list of DiffEntry objects:[one: “one” => “another”, three: “<undefined>” => “three”]Keys that would be added to the structure in this transaction have their values marked
as ‘<undefined>’.Nested lists and dictionaries are supported at an arbitrary level and will be indicated
using dot-separated paths. Changing a list’s member count will yield a DiffEntry indicating
a change in cardinality with a pound (#) sign.mylist.#: “3” => “4”This visualization is inspired by Terraform.LicenseMIT.
Package: ansible-ec2-inventory
Ansible EC2 inventory=====================This Python module is based on the [original Ansible EC2 inventoryscript](https://raw.githubusercontent.com/ansible/ansible/devel/contrib/inventory/ec2.py)that is linked in the [Ansibledocs](http://docs.ansible.com/ansible/intro_dynamic_inventory.html#example-aws-ec2-external-inventory-script).The Python module in this repo fixes a few issues by being-   installable via `pip` / PyPi: no need to place code from the Ansiblerepo in your inventory.-   extendable for your needs: the class `Ec2Inventory` can be used as abase class for customizations.Installation------------pip install ansible-ec2-inventoryUsage-----### As a scriptansible-ec2-inventory --config ec2.ini*Note:* if you want to provide a boto profile, prefix the command with`AWS_PROFILE=myprofile`.### As a Python moduleExample:``` {.python}from ansible_ec2_inventory import Ec2Inventoryimport jsondef main():# get path of ec2.inipath = os.path.dirname(os.path.realpath(__file__))# get inventoryec2inventory = Ec2Inventory(configfile=path + '/ec2.ini')data = ec2inventory.get_inventory()# print jsonprint(json.dumps(data, sort_keys=True, indent=2))if __name__ == '__main__':main()```
Package: ansible-filters-ldif
Ansible filter to read or write LDIF.Install this Ansible Filter:viapip:pip install ansible-filters-ldifviaansible-galaxy:ansible-galaxy install 'git+https://github.com/atterdag/ansible-filters-ldif.git'Ansible filters always runs on localhost.ExamplesConvert dictionary to LDIF----name:Create dictionary with entriesset_fact:dictionary:--dc=example,dc=com-dc:-exampledescription:-This is a line longer than 79 characters, so LDIF breaks it up over multiple lineso:-example.comobjectClass:-dcObject-organization--ou=people,dc=example,dc=com-objectClass:-organizationalUnitou:-people--cn=Jane Doe,ou=people,dc=example,dc=com-cn:-Jane Doemail:-jane.doe@example.comobjectClass:-inetOrgPersonsn:-Doe--cn=John Doe,ou=people,dc=example,dc=com-cn:-John Doemail:-john.doe@example.comobjectClass:-inetOrgPersonsn:-Doe--ou=groups,dc=example,dc=com-objectClass:-organizationalUnitou:-groups--cn=users,ou=groups,dc=example,dc=com-cn:-usersmember:-cn=Jane Doe,ou=people,dc=example,dc=com-cn=John Doe,ou=people,dc=example,dc=comobjectClass:-groupOfNames-name:"ConvertdictionarytoLDIFwhilewritingitto/tmp/test.ldifusing'to_ldif'filter"copy:content:"{{dictionary|to_ldif}}"dest:"/tmp/test.ldif"Convert LDIF to JSON----name:"Createmulti-linestringvariablewithLDIFdata"set_fact:ldif:|dn: dc=example,dc=comdc: exampledescription: This is one line which is longer than79 characters, so LDIF breaks it up over multiple linesobjectClass: dcObjectobjectClass: organizationo: example.comdn: ou=people,dc=example,dc=comobjectClass: organizationalUnitou: peopledn: cn=Jane Doe,ou=people,dc=example,dc=comobjectClass: inetOrgPersoncn: Jane Doesn: Doemail: jane.doe@example.comdn: cn=John Doe,ou=people,dc=example,dc=comobjectClass: inetOrgPersoncn: John Doesn: Doemail: john.doe@example.comdn: ou=groups,dc=example,dc=comobjectClass: organizationalUnitou: groupsdn: cn=users,ou=groups,dc=example,dc=comobjectClass: groupOfNamescn: usersmember: cn=Jane Doe,ou=people,dc=example,dc=commember: cn=John Doe,ou=people,dc=example,dc=com-name:"ConvertstringtoJSONwhilewritingitto/tmp/test.jsonusing'from_ldif'filter"copy:content:"{{(ldif|from_ldif)|to_nice_json}}"dest:"/tmp/test.json"Build dependenciesInstall the following OS development packages first.sudo apt-get install libssl-dev libldap2-dev libsasl2-dev python2-dev python3-dev
mkvirtualenv --python=/usr/bin/python3 python3-development
pip install --requirement requirements.txt
gem install travis fryLicenseGPLv3.
Package: ansible-flow
Ansible-flow is a simple utility to help make ansible easier to use with a
specific set of production use-cases.If you need to do the following, then ansible-flow might be for you:Use the same playbooks against multiple environmentsUse bastions in your deploymentRun a collection of playbooks in sequence.Links:GitHub:https://github.com/jmvrbanac/ansible-flowReadTheDocs:http://ansible-flow.readthedocs.org/en/latest/
Package: ansible-gendoc
Ansible-GendocInspired by Felix Archambault'sansidocproject.Anexamplegenerated withansible-gendoc.FeaturesGenerate the documentation for a role located in a directoryCan use a personal templateREADME.j2present in foldertemplatesQuickstartIf you have an existing README.md file in your role, backup it before !Run From dockerClone this project and build the image :gitcloneexportDOCKER_BUILDKIT=1dockerbuild.-tansible-gendoc:0.1.0-tansible-gendoc:latest
dockerrun--user$(id-u):$(id-g)-itansible-gendoc:latesthelpInstall python packageInstall the latest versionansible-gendocwithpiporpipxpipinstallansible-gendocUsageansible-gendoc--helpUsage:ansible-gendoc[OPTIONS]COMMAND[ARGS]...

╭─Options────────────────────────────────────────────────────────────────────────╮
│--version-vShowtheapplication'sversionandexit.│
│--install-completionInstallcompletionforthecurrentshell.│
│--show-completionShowcompletionforthecurrentshell,tocopy│
│itorcustomizetheinstallation.│
│--helpShowthismessageandexit.│
╰──────────────────────────────────────────────────────────────────────────────────╯
╭─Commands───────────────────────────────────────────────────────────────────────╮
│initCopytemplatesREADME.j2frompackagesintemplates/rolefolder.│
│renderBuildtheDocumentation│
╰──────────────────────────────────────────────────────────────────────────────────╯Build your first documentation of a roleTo build the documentation roles, you can run these commands :with package installed with pipansible-gendoc render.with docker imagesdocker run --user $(id -u):$(id -g) -v <path_role>:/role -it ansible-gendoc:latest render role.Use your personal templateTo use a personal template, you need toinitthe template in the templates
folder of your role. Ifansible-gendocfind an existing filetemplates/README.j2, it will use it to render the README.md file.ansible-gendocinit
lstemplates
README.j2The template usejinjaas templating
language.Modify it, for example replacehtmlorRestructuredtextor another language.
You can remove some variables too.Documentation of vars templateThe documentation of vars coming soon.
Package: ansible-generator
Ansible GeneratorDescriptionAnsible Generator is a python program designed to simplify creating a new
ansible playbook by creating the necessary directory structure for the user
based on ansible's best practices, as outlined incontent organization best practices.InstallationPIP (recommended)pip install -U ansible-generatorSourcegit clone https://github.com/kkirsche/ansible-generator.git
cd ansible-generator
curl -sSL https://install.python-poetry.org | python3 -
poetry buildUsageHelp Textusage: ansible-generate [-h] [-a] [-i INVENTORIES [INVENTORIES ...]]
                        [-r ROLES [ROLES ...]] [-v]
                        [-p PROJECTS [PROJECTS ...]] [--version]

Generate an ansible playbook directory structure

optional arguments:
  -h, --help            show this help message and exit
  -a, --alternate-layout
  -i INVENTORIES [INVENTORIES ...], --inventories INVENTORIES [INVENTORIES ...]
  -r ROLES [ROLES ...], --roles ROLES [ROLES ...]
  -v, --verbose
  -p PROJECTS [PROJECTS ...], --projects PROJECTS [PROJECTS ...]
  --version             show program's version number and exitDefaultsalternate-layout---Falseverbose---Falseinventories---['production', 'staging']roles---[]projects---[]ExampleCurrent directoryansible-generateNew-projectansible-generate -p playbook_nameAlternate Layoutansible-generate -aCustom Inventoriesansible-generate -i production staging labRolesThis portion of the tool relies on Ansible'sansible-galaxycommand line
applicationansible-generate -r role1 role2Output~/Downloads ❯❯❯ ansible-generate -i production staging lab -r common ubuntu centos -a -p network_security_baseline
creating directory /Users/example_user/Downloads/network_security_baseline/roles
creating directory /Users/example_user/Downloads/network_security_baseline/inventories/production/group_vars
creating directory /Users/example_user/Downloads/network_security_baseline/inventories/production/host_vars
creating directory /Users/example_user/Downloads/network_security_baseline/inventories/staging/group_vars
creating directory /Users/example_user/Downloads/network_security_baseline/inventories/staging/host_vars
creating directory /Users/example_user/Downloads/network_security_baseline/inventories/lab/group_vars
creating directory /Users/example_user/Downloads/network_security_baseline/inventories/lab/host_vars
creating file /Users/example_user/Downloads/network_security_baseline/inventories/production/hosts
creating file /Users/example_user/Downloads/network_security_baseline/inventories/staging/hosts
creating file /Users/example_user/Downloads/network_security_baseline/inventories/lab/hosts
creating file /Users/example_user/Downloads/network_security_baseline/site.yml
ansible galaxy output for role common:
- common was created successfully
ansible galaxy output for role ubuntu:
- ubuntu was created successfully
ansible galaxy output for role centos:
- centos was created successfully
Package: ansibleguy-webui
Basic WebUI for using AnsibleDISCLAIMER: This is anunofficial community project! Do not confuse it with the vanillaAnsibleproduct!The goal is to allow users to quickly install & run a WebUI for using Ansible locally.Keep it simple.This project is still in early development! DO NOT USE IN PRODUCTION!SetupLocal - PIPRequires Python >=3.10# installpython3-mpipinstallansibleguy-webui# runpython3-mansibleguy-webuiDockerdockerimagepullansible0guy/webui:latest
dockerrun-d--nameansible-webui--publish127.0.0.1:8000:8000ansible0guy/webui:latest# or with persistent data (volumes: /data = storage for logs & DB, /play = ansible playbook base-directory)dockerrun-d--nameansible-webui--publish127.0.0.1:8000:8000--volume$(pwd)/ansible/data:/data--volume$(pwd)/ansible/play:/playansible0guy/webui:latestDemoCheck out the demo at:demo.webui.ansibleguy.netLogin: Userdemo, PasswordAnsible1337UsageDocumentationContributeFeel free to contribute to this project usingpull-requests,issuesanddiscussions!Testers are also very welcome! Pleasegive feedbackSee also:ContributingRoadmapAnsible ConfigStatic Playbook-DirectoryGit Repository supportUsersManagement interface (Django built-in)Groups & Job PermissionsLDAP integrationSAML SSO integrationJobsExecute Ansible usingansible-runnerScheduled execution (Cron-Format)Manual/immediate executionSupport forad-hoc commandsJob LoggingWrite job metadata to databaseWrite full job-logs to FilesystemSecret handling (Connect, Become, Vault)User-specific job credentialsAlerting on FailureWebUIJob DashboardStatus, Execute, Time of last & next execution, Last run User, Links to Warnings/ErrorsJob OutputFollow the jobs output in realtimeJob ErrorsUI that allows for easy error analysis. Access to logs and provide links to possible solutionsShow Ansible Running-ConfigShow Ansible CollectionsCheck Collections for available updates (Galaxy + GitHub releases)Mobile SupportMulti-Language SupportAPIManage and execute JobsDatabaseSupport for MySQLTestingUnit TestsIntegration TestsBasic WebUI checksAPI EndpointsPermission system
Package: ansible-hostmanager
ansible-hostmanagerCLI script to work with Ansible hosts fileTo install:sudo pip3 install autopip
app install ansible-hostmanagerTo show hosts:$ahlist/etc/ansible/hosts exists and will be used. To change, run: ah set-hosts <PATH>
Inventory has 4 host(s)
app-server1         1.2.3.4   [app, all]
app-server2         1.2.3.6   [app, all]
web-server          1.2.3.5   [web, all]
db-server           1.2.3.7   [db, all]$ahlistappapp-server1         1.2.3.4   [app, all]
app-server2         1.2.3.6   [app, all]To ssh to a host:$ahsshdb#Runs`ssh1.2.3.7`$ahsshappFound multiple matches and will use first one: app-server1, app-server2#Runs`ssh1.2.3.4`$ahsshserver1ls/bin
boot
dev
...$ahssh-i~/.ssh/alternative_iduser@app1#Runs`ssh-i~/.ssh/alternative_iduser@1.2.3.4`#Aslongashostnameisfirst,orlast,argument,itwillgettranslated.#Toavoidhavingtoremember`ahssh`vs`ssh`,justcreatean`ssh`alias#asanynon-Ansiblehost/argswouldjustbepassedto`ssh`withoutchange.$aliasssh=`ahssh`$sshuser@not_ansible_hostLinks & Contact InfoPyPI Package:https://pypi.python.org/pypi/ansible-hostmanagerGitHub Source:https://github.com/maxzheng/ansible-hostmanagerReport Issues/Bugs:https://github.com/maxzheng/ansible-hostmanager/issuesFollow:https://twitter.com/MaxZhengXConnect:https://www.linkedin.com/in/maxzhengContact: maxzheng.os @t gmail.com
Package: ansible_importer
ansible_importerAnsible modules and plugins are typically pure Python, but often lack the structure necessary to import
as Python code. This package is meant to allow programmers to import module code for testing purposes.Usage..code-block:: pythonimport ansible_importer
ansible_importer.install(‘/abs/path/to/ansible/code’)# Assuming above path has a playbooks/plugins/actions/my_plugin.py module
from playbooks.plugins.actions.my_plugin import ActionModule# Assuming playbooks/library/glance
from playbooks.library.glance import ManageGlance# Assuming playbooks/inventory/dynamic_inventory.py
from playbooks.inventory import dynamic_inventory
Package: ansible-inventory-manage
This is a library to manipulate Ansible Inventories.It's independent of ansible by design, so that it doesn't need to trackansible code and is version independent.It only relies on what ansible expects as inventories (the json structure),which hasn't changed for a long time now.A standard inventory json is like this:```{_meta:{hostvars:{<hostname>:{var1: value1}}},all:{children: [],vars:{var2: value2},},groupname1:{children:[],hosts:[],}groupname2:{children:[],vars:{var3: value3},}}```This lib allows the loading of multiple jsons into memory, and manipulate theinventory objects, and vars precedence.Usage will explained in documentation soon.You can submit patches with git-review and gerrithub (``pip install git-review``)# git clone https://review.gerrithub.io/evrardjp/ansible-inventory-manage# git review -s# git checkout -b my_super_patch# git review -f
Package: ansible-later
ansible-laterAnother best practice scanner for Ansible roles and playbooksansible-later is a best practice scanner and linting tool. In most cases, if you write Ansible roles in a team, it helps to have a coding or best practice guideline in place. This will make Ansible roles more readable for all maintainers and can reduce the troubleshooting time. While ansible-later aims to be a fast and easy to use linting tool for your Ansible resources, it might not be that feature completed as required in some situations. If you need a more in-depth analysis you can take a look atansible-lint.ansible-later doesnotensure that your role will work as expected. For deployment tests you can use other tools likemolecule.You can find the full documentation athttps://ansible-later.geekdocs.de.CommunityGitHub Actionby@patrickjahnsContributorsSpecial thanks to allcontributors. If you would like to contribute,
please see theinstructions.ansible-later is a fork of Will Thamesansible-review. Thanks for your work on ansible-review and ansible-lint.LicenseThis project is licensed under the MIT License - see theLICENSEfile for details.
Package: ansible-lint
Ansible-lintansible-lintchecks playbooks for practices and behavior that could
potentially be improved. As a community-backed project ansible-lint supports
only the last two major versions of Ansible.Visit the Ansible Lint docs siteUsing ansible-lint as a GitHub ActionThis action allows you to runansible-linton your codebase without having to
install it yourself.# .github/workflows/ansible-lint.ymlname:ansible-linton:pull_request:branches:["main","stable","release/v*"]jobs:build:name:Ansible Lint# Naming the build is important to use it as a status checkruns-on:ubuntu-lateststeps:-uses:actions/checkout@v4-name:Run ansible-lintuses:ansible/ansible-lint@main# or version tag instead of 'main'For more details, seeansible-lint-action.ContributingPlease readContribution guidelinesif you wish to contribute.LicensingThe ansible-lint project is distributed asGPLv3due to use ofGPLv3runtime
dependencies, likeansibleandyamllint.For historical reasons, its own code-base remains licensed under a more liberalMITlicense and any contributions made are accepted as being made under
originalMITlicense.Authorsansible-lint was created byWill Thamesand is now maintained as part of theAnsiblebyRed Hatproject.