Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-42686

Can't run any playbook with roles

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not A Defect
    • Icon: Minor Minor
    • ansible-plugin
    • None
    • Jenkins ver. 2.32.3
      Ansible plugin v0.6.2
      ansible 1.7.2

      Maybe this is a known issue, but I can't run any playbook that uses roles.

      It seems like the plugin is somehow finding the role task file and is trying to construct an incorrect path to execute it, instead of the main playbook file.

      Here is a simple reproduction: https://github.com/orzarchi/ansible-plugin-repro

      Here is the pipeline to use with the reproduction: https://raw.githubusercontent.com/orzarchi/ansible-plugin-repro/master/pipeline.txt

      Running it results in the following error:
      [Deploy service] $ ansible-playbook repro.yml -i inventory.ini
      ERROR: file could not read: /var/jenkins_home/workspace/Deploy service/'/var/jenkins_home/workspace/Deploy service/roles/testrole/tasks/main.yml'
      FATAL: command execution failed

            sirot Jean-Christophe Sirot
            orzar or zarchi
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: