hashbangcode / vlad

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

tmp directory is not automatically created so vagrant up fails #288

Closed raj45 closed 8 years ago

raj45 commented 8 years ago

Reapperance of #167 - I am also using Ubuntu 14.04. This is the error where it fails:

TASK: [base | ensure certain vlad_aux subdirectories exist] ******************* 
failed: [192.168.100.100] => (item=tmp) => {"failed": true, "item": "tmp", "parsed": false}
BECOME-SUCCESS-ukryunbrffvmnueruzrjdtginfcmpfdn
Traceback (most recent call last):
  File "/home/vagrant/.ansible/tmp/ansible-tmp-1445002967.23-196068892008677/file", line 2012, in 
    main()
  File "/home/vagrant/.ansible/tmp/ansible-tmp-1445002967.23-196068892008677/file", line 279, in main
    os.mkdir(curpath)
OSError: [Errno 2] No such file or directory: '/var/www/site/vlad_aux/tmp'
OpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014
debug1: Reading configuration data /home/raj45/.ssh/config
debug1: /home/raj45/.ssh/config line 1: Applying options for *
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: auto-mux: Trying existing master
debug1: mux_client_request_session: master session id: 2
Shared connection to 192.168.100.100 closed.

failed: [192.168.100.100] => (item=db_io) => {"failed": true, "item": "db_io", "parsed": false}
BECOME-SUCCESS-xwrwddfjvinohhoumxftobnapjqhhgfl
Traceback (most recent call last):
  File "/home/vagrant/.ansible/tmp/ansible-tmp-1445002967.36-266518121813680/file", line 2012, in 
    main()
  File "/home/vagrant/.ansible/tmp/ansible-tmp-1445002967.36-266518121813680/file", line 279, in main
    os.mkdir(curpath)
OSError: [Errno 2] No such file or directory: '/var/www/site/vlad_aux/db_io'
OpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014
debug1: Reading configuration data /home/raj45/.ssh/config
debug1: /home/raj45/.ssh/config line 1: Applying options for *
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: auto-mux: Trying existing master
debug1: mux_client_request_session: master session id: 2
Shared connection to 192.168.100.100 closed.

FATAL: all hosts have already failed -- aborting

PLAY RECAP ******************************************************************** 
           to retry, use: --limit @/home/raj45/site.retry

192.168.100.100            : ok=4    changed=0    unreachable=0    failed=1   

Ansible failed to complete successfully. Any error output should be
visible above. Please fix these errors and try again.
dixhuit commented 8 years ago

Can you confirm what version of Vlad you're running?

dixhuit commented 8 years ago

The reason I ask is because up until a few days ago (dev branch) this task was performed with sudo (seemingly inexplicably). Perhaps this was the reason.

dixhuit commented 8 years ago

@raj45 Please can you try Vlad latest dev and let us know if you're still getting this error?

raj45 commented 8 years ago

@danbohea Absolutely, but I am not sure how to check out to the dev-version... I usually just git clone https://github.com/hashbangcode/vlad.git

dixhuit commented 8 years ago

If that's the case then it's likely that the change I committed today will not fix anything for you.

In case I'm wrong, here's how to grab the latest dev version via an existing local cloned repo:

git checkout dev
git pull

If you ever then want to jump back to master (the branch you had checked out by default) just run:

git checkout master
raj45 commented 8 years ago

Thanks for the guidance. I tried the latest dev-version, but get the same error...: OSError: [Errno 2] No such file or directory: '/var/www/site/vlad_aux/tmp'.

zxaos commented 8 years ago

@raj45 , if you create the tmp directory in the host OS before provisioning, does it work?

raj45 commented 8 years ago

@zxaos, this bug has disappeared in the master branch, I just made a complete Drupal installation with these commands:

git clone https://github.com/hashbangcode/vlad.git
cd vlad/
vagrant up --debug
vagrant ssh
drush dl --verbose --drupal-project-rename=example.local
cd example.local
drush site-install --db-url=mysql://vlad:wibble@localhost/vladdb --account-name=admin --account-pass=admin --yes