{"id":37670750,"url":"https://github.com/itential/itential.toolkit","last_synced_at":"2026-01-16T12:03:56.956Z","repository":{"id":289925283,"uuid":"810931087","full_name":"itential/itential.toolkit","owner":"itential","description":null,"archived":false,"fork":false,"pushed_at":"2025-04-25T19:31:02.000Z","size":185,"stargazers_count":0,"open_issues_count":5,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-25T19:43:42.643Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/itential.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-06-05T16:09:46.000Z","updated_at":"2025-04-25T19:31:02.000Z","dependencies_parsed_at":"2025-04-25T19:43:47.258Z","dependency_job_id":"ae1adfcc-4c2b-4052-9a70-0de9f4ce34b5","html_url":"https://github.com/itential/itential.toolkit","commit_stats":null,"previous_names":["itential/itential.toolkit"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/itential/itential.toolkit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itential%2Fitential.toolkit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itential%2Fitential.toolkit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itential%2Fitential.toolkit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itential%2Fitential.toolkit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/itential","download_url":"https://codeload.github.com/itential/itential.toolkit/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itential%2Fitential.toolkit/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28478422,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T11:59:17.896Z","status":"ssl_error","status_checked_at":"2026-01-16T11:55:55.838Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-01-16T12:03:56.875Z","updated_at":"2026-01-16T12:03:56.943Z","avatar_url":"https://github.com/itential.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Ansible Collection - itential.toolkit\nThis ansible project is intended to be a toolkit for operators of Itential\nAutomation Platform and Itential Automation Gateway. It includes Itential's\nrecommended methods for performing administration tasks, making adminstrative\nchanges to the platforms, and interrogating dependent systems for runtime\ninformation.\n\n## Connection Variables\n\nPlaybooks in this collection need to connect to some combination of:\n- **Ansible Hosts** (via SSH), or\n- The **Itential Platform Service** (via API).\n- The **IAG Service** (via API).\n\n### Ansible Connection Variables\nTo connect to the instances using Ansible:\n- `ansible_user`: The SSH username.\n- One of the following authentication methods:\n  - `ansible_password`: SSH password *(can be prompted with `--ask-pass`)*.\n  - `ansible_ssh_private_key_file`: Path to SSH private key *(can be passed with `--private-key`)*.\n\n### Itential Platform API Connection Variables\nTo connect to the Itential Platform API, provide \n- `platform_port`: The port that platform is accessible on\n- `platform_https`: Boolean that describes HTTPS (`true`) or HTTP (`false`) for the Platform API.\n- Either:\n    - `platform_username` and `platform_password`, **or**\n    - `platform_auth_token`.\n\n### IAG API Connection Variables\nTo connect to the IAG API, provide \n- `iag_port`: The port that IAG is accessible on\n- `iag_https`: Boolean that describes HTTPS (`true`) or HTTP (`false`) for the IAG API.\n- Either:\n    - `iag_username` and `iag_password`, **or**\n    - `iag_auth_token`.\n\n### Providing Variables\nVariables can be:\n- Defined in an **inventory file (hosts file)**.\n- Passed via the command line using `--extra-vars` or `-e`.\n- Encoded using ansible vault and provided by either of the above methods.\n\nExample:\n`ansible-playbook playbook.yml -i hosts.yaml --extra-vars 'platform_auth_token=\u003ctoken\u003e'`\n\n# Tools\n\n1. [Get Platform Token](#get-platform-token)\n2. [Restart Adapters](#restart-adapters)\n3. [Metrics](#metrics)\n4. [Adjusting Adapters' Log Level](#adjusting-adapters-log-level)\n5. [Starting/Stopping Workers](#startingstopping-workers)\n6. [Sync IAG Custom Script Schema](#sync-iag-custom-script-schema)\n7. [Dependencies Version](#dependencies-version)\n8. [Job and Task Worker Status](#job-and-task-worker-status)\n9. [RBAC Settings](#rbac-settings)\n10. [IAG Refresh Custom Scripts](#iag-refresh-custom-scripts)\n11. [Restart Platform](#restart-platform)\n12. [Restart IAG](#restart-iag)\n13. [IAG Fakenos](#iag-fakenos)\n14. [MongoDB Change Password](#mongodb-change-password)\n15. [Redis Change Password](#redis-change-password)\n16. [Sentinel Change Password](#sentinel-change-password)\n17. [Step Down Mongo Primary](#step-down-mongo-primary)\n18. [Step Down Redis Primary](#step-down-redis-primary)\n\n\n## Get Platform Token\nThis tool will fetch a platform session token and display it to the screen.\nThis playbook requries Platform API access.\n\n### Example\n`ansible-playbook playbooks/get_platform_token.yml -i hosts.yaml --extra-vars 'platform_username=\u003csome-user\u003e platform_password=\u003csome-password\u003e'`\n\n## Restart Adapters\nThis tool will restart a list of provided adapter names after fetching an IAP\nsession token. This playbook requries Platform API access.\n\n### Required Variables\n\n| NAME              | DESCRIPTION                                       |\n|-------------------|---------------------------------------------------|\n| adapters          | Comma separated list of adapter names to restart  |\n\n### Example\n`ansible-playbook playbooks/restart_adapters.yml -i hosts.yaml adapters=\u003ccomma-separated-list-of-adapter-names\u003e'`\n\n## Metrics\nThis tool will show the quantity of workflows, templates, MOP templates, \nanalytic templates, JSTs, JSON forms, forms, jobs and automations in IAP. \nThis playbook requries Platform API access.\n\n### Example\n`ansible-playbook playbooks/metrics.yml -i hosts.yaml`\n\n## Adjusting Adapters' log level\nThis tool will adjust the log level of the adapters in IAP. Available options are \n`error, warn, info, debug, trace, spam`. This playbook requries Platform API access.\n\n### Required Variables\n\n| NAME         | DESCRIPTION                                                     |\n|--------------|-----------------------------------------------------------------|\n| log_level    | The log level to be set (error, warn, info, debug, trace, spam) |\n| adapters     | Comma separated list of adapters to update                      |\n\n### Example\n`ansible-playbook playbooks/adapters_log_level.yml -i hosts.yaml --extra-vars log_level=error'`\n\n## Starting/Stopping Workers\nThese playbooks will start or stop **task workers** and/or **job workers** (supported in Platform 2023.1 and later).\nThese playbooks requrie Platform API access.\n\n### Playbooks\nEach action has its own playbook:\n- `start_task_worker.yml`\n- `stop_task_worker.yml`\n- `start_job_worker.yml`\n- `stop_job_worker.yml`\n\n### Example Usage\n`ansible-playbook start_task_worker.yml -i hosts.yaml`\n\n## Sync IAG Custom Script Schema\nThis tool will grab the JSON schema(decorations) of the custom script from the first IAG host in the `gateway` group and applies it to the custom script across other IAG hosts in the `gateway` group.\nThis playbook requries IAG API access.\n\n### Required Variables\n\n| NAME              | DESCRIPTION                                                                                 |\n|-------------------|---------------------------------------------------------------------------------------------|\n| script_name       | Name of the custom script                                                                   |\n\n\u003e **_NOTE:_**  Make sure that the first host in the `gateway` group has the latest JSON schema.\n\n### Example\n`ansible-playbook sync_iag_script_schema.yml -i hosts --extra-vars 'script_name=hello.py'`\n\n## Dependencies Version\nThis tool will return the version of redis, rabbitmq, mongobd, IAP components, and IAG components. More information about the dependencies can be found in [this](https://docs.itential.com/docs/itential-dependencies-consolidated) page. The rabbitmq server, redis server, IAP server and IAG server\nshould be under their respective group in the hosts file.\nThis playbook requries ansible host access.\n\n### Required Variables\n\n| NAME         | DESCRIPTION                                                                           |\n|--------------|---------------------------------------------------------------------------------------|\n| component   | The component(mongodb, redis, etc) to target to. Available options are:                |\n|              |  `mongodb` : Returns the version of mongodb                                           |\n|              |  `redis` : Returns the version of redis                                               |\n|              |  `rabbitmq` : Returns the version of rabbitmq                                         |\n|              |  `platform` : Returns the version of mongodb, redis, rabbitmq, and IAP dependencies   |\n|              |  `gateway` : Returns the version of IAG dependencies.                                 |\n|              |  `all` : Returns the version across all five components.                              | \n\n### Example\n`ansible-playbook playbooks/dependencies_version.yml -i hosts --extra-vars 'component=all'`\n\n## Job and Task Worker Status\nThis tool will return the status of job worker and task worker of IAP.\nThis playbook requries Platform API access.\n\n### Example\n`ansible-playbook playbooks/job_worker_status.yml -i hosts`\n\n## RBAC Settings\nThis playbook retrieves **RBAC (Role-Based Access Control)** settings for one or more users in the Platform. It gathers authorization accounts and roles from the Platform API, processes the data, and displays the assigned roles for the specified users.\nThis playbook requries Platform API access.\n\n### Required Variables\n\n| NAME                | DESCRIPTION                                                                |\n|---------------------|----------------------------------------------------------------------------|\n| users               | A single username (string) or a list of usernames.                         |\n\n---\n\n### Example Usage\n\nGet RBAC settings for multiple users using username/password:\n`ansible-playbook rbac_settings.yml -i hosts.yaml --extra-vars users=[\"user1\",\"user2\"]'`\n\n## IAG Refresh Custom Script\nThis tool will refresh the custom scripts cache in IAG. Furthermore, it also restarts the AGManager application and the IAG adapters in the IAP so that the updated scripts can be accessed from the IAP. The IAP hostnames should be under `platform` group and the IAG hostnames should be under the `gateway` group inside the host file.\nThis playbook requries Platform API and IAG API access.\n\n### Example\n`ansible-playbook playbooks/iag_refresh_custom_scripts.yml -i hosts --extra-vars 'iap_username=\u003csome-username\u003e iap_password=\u003csome-password\u003e iag_username=\u003csome-username\u003e iag_password=\u003csome-password\u003e'`\n\n## Restart Itential Platform\nThis tool will perform a safe restart the Itential Platform. It turns off task and job workers then waits until there are no\nin progress jobs before restarting the Platform. The playbook requires ansible host and Platform API access.\n\n### Example\nRunning playbook when password/key file is defined in the hosts file\n\n`ansible-playbook playbooks/restart_platform.yml -i hosts`\n\n## Restart IAG\nThis tool will restart the IAG.\nThis playbook requries ansible host access.\n\n### Example\nRunning playbook when password/key file is defined in the hosts file\n\n`ansible-playbook playbooks/restart_iag.yml -i hosts`\n\nRunning playbook by providing key file from command-line\n\n`ansible-playbook playbooks/restart_iag.yml -i hosts --private-key \u003ckey_file_name\u003e`\n\nRunning playbook by providing username and password from command-line\n\n`ansible-playbook playbooks/restart_iag.yml -i hosts -u \u003cssh_username\u003e --ask-pass \u003cpassword\u003e`\n\n## IAG Fakenos\nThis tool will install and start fakenos which will create mock devices on an IAG host.\nThe playbook requires ansible host access.\n\n### Required Variables\n\n| NAME             | DESCRIPTION                                                     |\n|------------------|-----------------------------------------------------------------|\n| fakenos_devices  | Object containing the device type. Each device type needs vendor, platform, and count      |\n\n\n### Example Inventory variable\n\n```\nfakenos_devices:\n  cisco_ios:\n    vendor: cisco\n    platform: ios\n    count: 5\n  juniper_junos:\n    vendor: junipernetworks\n    platform: junos\n    count: 5\n```\n\n### Example\n\nRunning playbook when fakenos_devices is defined in the inventory file\n\n`ansible-playbook rbac_settings.yml -i hosts.yaml`\n\n## Mongodb Change Password\nThis tool will update the password for the 'itential' user in the mongo database.\nIt also updates the platform configuration and restarts the platform.\nThe playbook requires ansible host access for mongo and platform.\n\n| NAME             | DESCRIPTION                                                     |\n|------------------|-----------------------------------------------------------------|\n| mongo_admin_password  | the password for the 'admin' user in the mongo database      |\n| mongo_new_password  | The new password for the itential user                        |\n\n### Example\n`ansible-playbook mongodb_change_password.yml -i hosts.yaml --extra-vars \"mongo_admin_password=password mongo_new_password=newpassword\"`\n\n## Redis Change Password\nThis tool will update the password for the 'itential' user in the Redis configuration file.\nIt also updates the platform configuration and restarts the platform.\nThe playbook requires ansible host access for redis and platform.\n\n| NAME             | DESCRIPTION                                                     |\n|------------------|-----------------------------------------------------------------|\n| redis_new_password  | The new password for the itential user                       |\n\n### Example\n`ansible-playbook redis_change_password.yml -i hosts.yaml --extra-vars \"redis_new_password=newpassword\"`\n\n## Sentinel Change Password\nThis tool will update the password for the 'sentineluser' user in the Redis and Sentinel configuration files.\nIt also updates the platform configuration and restarts the platform.\nThe playbook requires ansible host access for redis and platform.\n\n| NAME             | DESCRIPTION                                                     |\n|------------------|-----------------------------------------------------------------|\n| sentinel_new_password  | The new password for the sentineluser user                |\n\n### Example\n`ansible-playbook sentinel_change_password.yml -i hosts.yaml --extra-vars \"sentinel_new_password=newpassword\"`\n\n## Step Down Mongo Primary\nThis tool forces a mongo re-election for a new Mongo Primary.\nThe playbook requires ansible host access for mongodb.\n\n| NAME             | DESCRIPTION                                                     |\n|------------------|-----------------------------------------------------------------|\n| mongo_admin_password | The password for the admin user in the mongodb              |\n\n### Example\n`ansible-playbook stepdown_mongo_primary.yml -i hosts.yaml --extra-vars \"mongo_admin_password=password\"`\n\n## Step Down Redis Primary\nThis tool forces a redis re-election for a new Redis Primary.\nThe playbook requires ansible host access for redis\n\n| NAME             | DESCRIPTION                                                     |\n|------------------|-----------------------------------------------------------------|\n| redis_password   | The password for the admin user in redis             |\n\n### Example\n`ansible-playbook stepdown_redis_primary.yml -i hosts.yaml --extra-vars \"redis_password=password\"`\n\n# Roles\n\n## Auth Token\nThis role retrieves and stores the auth token from the platform API. It is used in playbooks that need\nto make many api requests so that ansible doesn't have to re-authenticate each time it wants to make a request.\nThis role requires platform API access\n\n## Restart Adapters\nThis role makes an API call to restart all of the adapters from the 'adapter_names' list.\nIt requires platform API access\n\n## Restart Platform\nThis role contains the logic to do a safe restart of the platform. It includes a handler that can be\nused when the role is imported. This role does not contain a main task file, so to run it the restart.yml\ntask file or the handler must be explicitly called.\nThis role requires platform API access","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fitential%2Fitential.toolkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fitential%2Fitential.toolkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fitential%2Fitential.toolkit/lists"}