Skip to content
This repository has been archived by the owner on Aug 13, 2024. It is now read-only.

Unable to run the playbook (skipped tasks throw an error about with_items) #101

Closed
MickaelBergem opened this issue Mar 9, 2016 · 5 comments
Labels

Comments

@MickaelBergem
Copy link

I just upgraded this role to the last version (1.11.4) and it does not run anymore. I am getting the following error:

TASK: [jdauphant.nginx | Find enabled sites] ********************************** 
skipping: [default]

TASK: [jdauphant.nginx | Disable unmanaged sites] ***************************** 
skipping: [default] => (item=enabled_sites.stdout_lines)

TASK: [jdauphant.nginx | Find config files] *********************************** 
skipping: [default]

TASK: [jdauphant.nginx | Remove unmanaged config files] *********************** 
fatal: [default] => with_items expects a list or a set

This seems to be an issue with Ansible itself (with_items + skipped tasks), but affects this role.
I am using Ansible 1.9.4 (latest release) with a standard nginx configuration dictionnary.

Downgrading to the version 1.11.1 of the role solved my issue.

@jdauphant
Copy link
Owner

The last release of ansible is "2.0.1.0", some patch have been made to support ansible 2.
If you want to use old release of ansible try with version v1.11.1 of the role.

@jdauphant
Copy link
Owner

@MickaelBergem Have you solve the problem with one of the solution ?

@salazarp
Copy link

Same problem here using Ansible 1.9.1. The problem occurs when calling "remove-extras.yml". But if I am understanding correctly tasks/main.yml, that routine should only fire when variable "keep_only_specified" is set. And both the default role config and my local vars set specifically "keep_only_specified: False", yet "remove-extras.yml" still executes. How is this? I'm just trying to understand the reason so I can get around it cleanly without editing your role.

@jdauphant
Copy link
Owner

@salazarp Do you version v1.11.1 or less of this role ?
Because version after v1.11.1 are only compatible with Ansible 2.0 and after.

@salazarp
Copy link

No, I am using 2.0.1 of your role (I wasn't aware of the Ansible2 requirement when I got it).
I'll be upgrading soon enough, but in the meantime commenting out "remove-extras.yml" from main.yml works for me.

Btw, thanks for the role! Nice and elegant, a great time saver.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants