hashbangcode / vlad

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

composer.sh fails with mode="a+x" but works with mode ="755" #215

Closed tweevick closed 9 years ago

tweevick commented 9 years ago

Hello I'm new to git and vlad, In composer.yml is writtent: mode="a+x ->this fails for me, but changing to mode ="755" works

philipnorton42 commented 9 years ago

Hi @tweevick, thanks for posting :)

If you could run the following command and print the output then I can make sure we are on the same page. One or two problems recently have come from differences in software versions so this is a quick way of finding out your current setup and perhaps replicating.

echo "VirtualBox `VBoxManage --version`"; vagrant --version; ansible --version; vagrant plugin list

For more information on this command see our doc site: http://vlad-docs.readthedocs.org/en/latest/contributing/submitting_issues/

Thanks!

mbarcia commented 9 years ago

Which version of ansible are you using? I think it needs to be 1.8+. El 24/04/2015 17:32, "tweevick" notifications@github.com escribió:

Hello I'm new to git and vlad, In composer.yml is writtent: mode="a+x ->this fails for me, but changing to mode ="755" works

  • name: composer | add Composer shared vendor directory to path template: src=composer.j2 dest=/etc/profile.d/composer.sh mode="a+x" tags: composer sudo: true Error message 2015-04-24 16:22:05,703 p=16448 u=peter | failed: [vlad] => {"details": "invalid literal for int() with base 8: 'a+x'", "failed": true, "gid": 0, "group": "root", "mode": "0644", "owner": "root", "path": "/etc/profile.d/composer.sh", "size": 201, "state": "file", "uid": 0} 2015-04-24 16:22:05,703 p=16448 u=peter | msg: mode needs to be something octalish

— Reply to this email directly or view it on GitHub https://github.com/hashbangcode/vlad/issues/215.

keithcrooks commented 9 years ago

I've experienced this problem today too but only on my work Mac Mini but don't get it on my personal MacBook Pro or a friends MacBook Pro.

On the one it's failing on, the above command outputs the following:

VirtualBox 4.3.6r91406 Vagrant 1.6.5 ansible 1.7.2 vagrant-hostsupdater (0.0.11) vagrant-login (1.0.1, system) vagrant-share (1.1.3, system) vagrant-triggers (0.5.0)

The one that works is:

VirtualBox 4.3.26r98988 Vagrant 1.6.5 ansible 1.9.0.1 configured module search path = None vagrant-cachier (1.2.0) vagrant-hostsupdater (0.0.11) vagrant-login (1.0.1, system) vagrant-share (1.1.3, system) vagrant-triggers (0.5.0)

I'll try to update ansible on my work machine and see if that helps.

philipnorton42 commented 9 years ago

I would upgrade ansible as a first cause of action. This can be done using:

sudo pip install --upgrade ansible

Be careful though as there is currently a problem with Ansible 1.9 and the Solr role in Vlad. If you want to install a compatible version then you can do the following:

sudo pip uninstall ansible
sudo pip install ansible==1.8.4

If you aren't using Solr then it doesn't matter much :)

keithcrooks commented 9 years ago

I'm not using Solr at the moment I'm just integrating VLAD into a simple existing project for evaluation purposes.

It's looking good so far and I think it fits our needs exactly.

If that's the case then going forward I will need to use Solr so thanks for the heads up!

keithcrooks commented 9 years ago

You were right, it was the ansible version.

I've upgraded to 1.8.4 and it provisions fine now.

Thanks.

philipnorton42 commented 9 years ago

That's good news. I think what we need really is some way of forcing a minimum Ansible version. We already do the same for Vagrant and it should solve any errors like this for first time users.

dixhuit commented 9 years ago

I think what we need really is some way of forcing a minimum Ansible version.

This issue requires the opposite - a maximum Ansible version (at least until we can address the root cause). But yes, there are probably other issues that would not pop up if we enforced a minimum too. So we need an upper and lower version :)

It looks like this is all possible via Ansible itself: https://github.com/ansible/ansible/pull/6619

philipnorton42 commented 9 years ago

I've added the check to detect Ansible under version 1.8.4. I did contemplate a maximum version but I think having a minimum version is a must, where as a maximum version only counts whilst there are bugs we can't fix or a certain version breaks Vlad. I've sorted the Solr issue so all we need to do is roll this update.

dixhuit commented 9 years ago

Yay. Avoiding a max version is certainly the way to go if we can :)

philipnorton42 commented 9 years ago

This version enforcement is now in a full release so I'm going to close this now.