hashbangcode / vlad

Vlad - Vagrant LAMP Ansible Drupal
173 stars 53 forks source link

Fix minimum Ansible version check. #326

Closed zxaos closed 7 years ago

zxaos commented 8 years ago

vlad will fail to provision on old versions of ansible, because it tries to load the roles from galaxy instead of github.

I had a dev just try to bring a VM up using ansible 1.7.2 and it failed provisioning. Could we error out on old, unsupported versions?

dixhuit commented 8 years ago

I honestly thought that we already did but now that you raise it, I can't spot the code at a glance.

Yes, if it's not already in there, let's add it.

philipnorton42 commented 8 years ago

I'm sure we added this in as well, but maybe that was just for older versions of Vagrant?

dixhuit commented 8 years ago

Yeah, the Vagrant check is definitely there - couldn't see anything for Ansible though.

philipnorton42 commented 8 years ago

Ah, found it. At the top of site.yml there is an Ansible version check:

    - name: Check Ansible version compatibility
      fail: msg="The minimum Ansible version required to run Vlad is 1.8.4. To upgrade run 'sudo pip install --upgrade ansible'."
      when: ansible_version.major|int == 1 and ansible_version.minor|int < 9 and ansible_version.revision|int < 4

I guess this doesn't work :)

philipnorton42 commented 7 years ago

The ansible version check is now part of the system and I have tested it with differing version numbers. The minimum version is currently 2.1.x due to some of the way in which variables are processed.