{"id":18086130,"url":"https://github.com/axmetishe/kitchen-yansible","last_synced_at":"2026-04-29T06:38:28.700Z","repository":{"id":50002872,"uuid":"231561135","full_name":"axmetishe/kitchen-yansible","owner":"axmetishe","description":"Yet Another Ansible Test Kitchen Provisioner","archived":false,"fork":false,"pushed_at":"2021-06-06T10:01:56.000Z","size":77,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"develop","last_synced_at":"2025-12-04T09:11:16.049Z","etag":null,"topics":["ansible","ansible-provisioners","ansible-windows","kitchen-ansible","test-kitchen"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/axmetishe.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-01-03T10:03:41.000Z","updated_at":"2021-06-06T09:39:15.000Z","dependencies_parsed_at":"2022-09-08T20:11:37.844Z","dependency_job_id":null,"html_url":"https://github.com/axmetishe/kitchen-yansible","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/axmetishe/kitchen-yansible","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axmetishe%2Fkitchen-yansible","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axmetishe%2Fkitchen-yansible/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axmetishe%2Fkitchen-yansible/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axmetishe%2Fkitchen-yansible/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/axmetishe","download_url":"https://codeload.github.com/axmetishe/kitchen-yansible/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axmetishe%2Fkitchen-yansible/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32414422,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T06:29:02.080Z","status":"ssl_error","status_checked_at":"2026-04-29T06:29:00.631Z","response_time":110,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: 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":["ansible","ansible-provisioners","ansible-windows","kitchen-ansible","test-kitchen"],"created_at":"2024-10-31T16:06:41.619Z","updated_at":"2026-04-29T06:38:28.664Z","avatar_url":"https://github.com/axmetishe.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# kitchen-yansible\n\nYet Another Ansible [Test Kitchen](https://github.com/test-kitchen/test-kitchen) Provisioner\n\n[![Gem Version](https://badge.fury.io/rb/kitchen-yansible.svg)](http://badge.fury.io/rb/kitchen-yansible)\n[![Gem Downloads](http://ruby-gem-downloads-badge.herokuapp.com/kitchen-yansible?type=total\u0026color=brightgreen)](https://rubygems.org/gems/kitchen-yansible)\n[![Build Status](https://travis-ci.org/axmetishe/kitchen-yansible.svg?branch=develop)](https://travis-ci.org/axmetishe/kitchen-yansible)\n\n## Why another\nFor a long time I used to work with SaltStack with integration testing for at least two platforms and it was\na great experience, special thanks to eco-system created by SaltStack team and [Daniel Wallace](https://github.com/gtmanfred)\nfor his 'salt-solo' provisioner especially.\n\nNow I'm working with Ansible and just want to maintain the same development comfort as with SaltStack.\n\nAs was mentioned before this plugin was inspired by three other provisioners with different configuration behaviour and\neven another configuration management tool provisioner:\n[kitchen-ansible](https://github.com/neillturner/kitchen-ansible) - installation on the instance under test and execution against localhost\n[kitchen-ansiblepush](https://github.com/ahelal/kitchen-ansiblepush) - Ansible execution from host system on the instance under test\n[kitchen-salt](https://github.com/saltstack/kitchen-salt) - SaltStack CM tool provisioner\n\nBoth Ansible provisioners are good at their purpose but when you are working with different platforms especially\nwith the triple at same time you have to use different provisioners.\nFor instance 'kitchen-ansible' has dependency management but is able to test Windows platform only using linux\ntest instance provisioned at the same time, on the other hand 'ansible-push' is able to test Windows directly but\nhas nothing to work with dependencies unfortunately and you will have to manage them manually or using\nthird-party tools like 'librarian-ansible', ansible-galaxy or something other.\n\nSaltStack provisioner has all of this and I'm going to provide the same functionality for the Ansible.\n\nYes, I know about [Molecule](https://github.com/ansible/molecule) which is designed to work with Ansible, but it limited\nto Ansible only and looks not so powerful for me as the Test Kitchen, moreover I saw a lot of Dev cases when you\nhave no ability to pin to specific system and, in general, why you even would to limit yourself?=)\n\n## About\nThis provider has two major features - local and remote execution using single provisioner.\n\nWhy is that matter? - Well, Ansible was created as masterless/agentless configuration management tool for simple\nmanagement from any place without dedicated master, so the provisioner for Ansible must have the same behaviour obviously.\nDespite the fact I'm not an Ansible fan I like when tool is used at purpose - you wouldn't want to use a microscope to\nhammer a nail=)\n\nOn the other hand Ansible modules would not work without Python installed(agentless - heh=) on instance under test\nwhich are force us to manage Python installation for containerized instances and in case we need to install Python,\nwhy we can't install Ansible as well?\nOr maybe you just don't want to install some Python dependencies locally required for Ansible?\nThat is why remote installation is also takes a place.\n\n## How to install\n`gem install kitchen-yansible`\n\n## How to install from sources\n`gem build kitchen-yansible.gemspec \u0026\u0026 gem install kitchen-yansible-0.0.1.gem`\n\n## How to use\nYou need to install the gem and define the provisioner in general.\n```yaml\nprovisioner:\n  name: yansible\n```\n\n### Default configuration\nThe simple configuration above will initialize provisioner with default options like:\n- Local Ansible execution, e.g. \"push\" mode.\n- In case Ansible is not installed locally we will try to use Python Virtualenv binary in order to install latest\nAnsible into instance sandbox directory.\n- When we will be able to use Ansible we will run it against 'default.yml' playbook at the kitchen root diretory\n\n### Provisioner options\n```yaml\nprovisioner:\n  name: yansible\n\n  # Defines the version of Ansible to install into sandbox or on the instance under test\n  ansible_version: 2.7.12\n\n  # Forces sandbox creation on the host for \"push\" mode even Ansible is installed locally\n  sandboxed_executor: true\n\n  # Switch executor to remote installation on instance under test - except for Windows platform\n  remote_executor: true\n\n  # Enable Ansible verbose output - '-v'\n  ansible_verbose: true\n\n  # Ansible verbosity level - '-vvvv'\n  ansible_verbosity: 4\n\n  # Dependencies management\n  dependencies:\n    # Path dependency - will be copied into sandbox recursively, excluding '.git/' directory\n    - name: 'jdk'\n      # Relative or absolute path to the role root directory\n      path: '../jdk/roles/jdk'\n\n    # Git dependency - will be cloned using shallow clone to specified git ref\n    - name: 'mysql'\n      # Only Git VCS supported at the moment\n      repo: 'git'\n      url: 'https://github.com/geerlingguy/ansible-role-mysql.git'\n      # Valid git ref, e.g. branch, tag, or even commit hash\n      ref: '1.6.0'\n\n  # Allow to change main executable binary\n  ansible_binary: 'ansible-playbook'\n\n  # Copy to sandbox and enable Ansible config usage\n  ansible_config: nil\n\n  # Override default roles directory\n  ansible_roles_path: 'roles'\n\n  # Extra arguments to pass to Ansible command as-is\n  ansible_extra_arguments:\n    - '-e \"version=1.23.45 other_variable=foo\"'\n\n  # Force colorized stdout\n  ansible_force_color: true\n\n  # Disable/Enable host key check\n  ansible_host_key_checking: false\n\n  # Auth transport for WinRM - 'Basic' if not defined\n  ansible_winrm_auth_transport: nil\n\n  # Ignore WinRM connection certificate issues - 'ignore', 'validate'\n  ansible_winrm_cert_validation: 'ignore'\n```\n\n### Complex example\n```yaml\ndriver:\n  name: docker\n\nprovisioner:\n  name: yansible\n  ansible_verbose: true\n  dependencies:\n    - name: 'jdk'\n      path: '../jdk/roles/jdk'\n    - name: 'mysql'\n      repo: 'git'\n      url: 'https://github.com/geerlingguy/ansible-role-mysql.git'\n      ref: '1eee6e262bff56094398cbb285b44634b9763349'\n  ansible_extra_arguments:\n    - '-e \"version=1.23.45 other_variable=foo\"'\n\nplatforms:\n  # Vagrant driver\n  - name: ubuntu-vagrant\n    driver:\n      name: vagrant\n      provider: libvirt\n      box: generic/ubuntu1804\n\n  # Make sure that Windows box template forward WinRM ports, winrm transport and\n  # user credentials are correct\n  - name: windows\n    transport:\n      name: winrm\n      username: 'user'\n      password: 'user'\n      winrm_transport: :ssl\n    driver:\n      name: vagrant\n      provider: libvirt\n      box: local/windows\n      vagrantfile_erb: 'Vagrant-template'\n    driver_config:\n      communicator: winrm\n    provisioner:\n      remote_executor: false\n\n  - name: macos\n    driver:\n      name: vagrant\n      provider: libvirt\n      box: macos-10.15-catalina\n      vagrantfile_erb: 'osx/Vagrantfile'\n    provisioner:\n      remote_executor: false\n\n  # Docker driver\n  ## RHEL-based\n  - name: centos-6\n  - name: centos-7\n    driver_config:\n      provision_command:\n        - yum install -y unzip tar\n  - name: centos-8\n  - name: oraclelinux-6\n  - name: oraclelinux-7\n  - name: oraclelinux-8\n  - name: fedora-26\n  - name: fedora-27\n  - name: fedora-28\n  - name: fedora-29\n  - name: fedora-30\n  - name: fedora-31\n  - name: amazonlinux-1\n  - name: amazonlinux-2\n\n  ## Debian-based\n  - name: debian-7\n    driver_config:\n      image: local/debian:7\n  - name: debian-8\n  - name: debian-9\n  - name: debian-10\n  - name: ubuntu-14.04\n  - name: ubuntu-16.04\n  - name: ubuntu-18.04\n  - name: ubuntu-19.04\n  - name: ubuntu-19.10\n\n  # Docker driver, systemd init system\n  - name: centos-8-systemd\n    driver:\n      volume: /sys/fs/cgroup:/sys/fs/cgroup:ro\n      cap_add:\n        - SYS_ADMIN\n    driver_config:\n      image: local/centos8-systemd:1.0\n      run_command: /sbin/init\n  - name: amazonlinux-2-systemd\n    driver:\n      volume: /sys/fs/cgroup:/sys/fs/cgroup:ro\n      cap_add:\n        - SYS_ADMIN\n    driver_config:\n      image: local/amazonlinux2-systemd:1.0\n      run_command: /usr/sbin/init\n  - name: ubuntu-18.04-systemd\n    driver:\n      volume: /sys/fs/cgroup:/sys/fs/cgroup:ro\n      cap_add:\n        - SYS_ADMIN\n    driver_config:\n      image: local/ubuntu18.04-systemd:1.0\n      run_command: /lib/systemd/systemd\n```\n\n## TODO\n\n* Dependencies mgmt - librarian-ansible\n* Remote installation via pkgmgr\n* Platforms:\n  * Darwin\n  * Alpine\n  * Suse\n  * *BSD\n* Vars from kitchen.yml with recursive merge for suite overrides\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faxmetishe%2Fkitchen-yansible","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faxmetishe%2Fkitchen-yansible","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faxmetishe%2Fkitchen-yansible/lists"}