WunderTools icon indicating copy to clipboard operation
WunderTools copied to clipboard

Repository installation fails with: "Error: Nothing to do"

Open mikaelkundert opened this issue 8 years ago • 0 comments

I got an error while provisioning after couple failures with:

- yum:
    name={{item}}
    state=present
  with_items:
    - "https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm"
  when: distro == "rhel7"

Resulting in error with stderr "Error: Nothing to do"

I think this is because the repository is already installed? Perhaps adding additional condition could help as so:

- yum:
    name={{item}}
    state=present
  with_items:
    - "https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm"
  when: distro == "rhel7" and first_run is defined

mikaelkundert avatar Jan 10 '17 10:01 mikaelkundert