Provisioning failing during TASK [Get software for Python-based control.]
I have one Windows 7 machine that is giving me problems getting Drupal VM running.
I've updated the box via vagrant box update
I've updated Ansible inside the VM using
sudo pip install ansible --upgrade sudo ansible-galaxy install -r provisioning/requirements.yml --force
I destroyed the VM and tried again and continue to get hung up at during vagrant provision:
==> WebNY: TASK [Get software for Python-based control.] ********************************** ==> WebNY: An exception occurred during task execution. To see the full traceback, use -vvv. The error was: AttributeError: 'list' object has no attribute 'split' ==> WebNY: failed: [localhost] => (item=[u'curl', u'python-apt', u'python-pycurl', u'build-essential']) => {"failed": true, "item": ["curl", "python-apt", "python-pycurl", "build-essential"], "parsed": false} ==> WebNY: to retry, use: --limit @/vagrant//provisioning/playbook.retry ==> WebNY:
Not sure what to try next to solve the issue.
I seem to remember seeing this error once before, but no clue when it happened or how it was fixed (probably just a destroy and up again)... have you been able to try that?
Also, what version of ansible is installed? 2.0.1 or something else? And maybe make sure Drupal VM itself is up to date if everything else is up to date as well.
Have you been able to get past this particular issue? It sounds like either one of the roles is out of date, or Ansible is out of date.
I'm getting this issue right now on OS X.
Ansible: 2.0.1.0 Vagrant: 1.8.1 Virtualbox: 5.0.16 drupal-vm: master branch just pulled
@scottatdrake - Are you on windows as well, or on a different platform?
Also, have you run: sudo ansible-galaxy install -r provisioning/requirements.yml --force ?
@geerlingguy I'm on OS X and yes, have run sudo ansible-galaxy install -r provisioning/requirements.yml --force. Doing a vagrant destroy and vagrant up hasn't seemed to help.
Okay, I just got by the point that was hanging. It seemed like the previous task (apt cache update) was taking a long time, as well. So, I did a vagrant ssh followed by sudo apt-get update, exited, then tried vagrant provision again. I have no idea if that fixed the issue, or if perhaps there was just some sort of connectivity problem, but it seems to be working now. ¯(ツ)/¯
Had the same issue and did what @scottatdrake did with one minor variation/addition:
vagrant sshinto the boxsudo apt-get updaterevealed a need to runsudo dpkg --configure -a.- so, ran
sudo dpkg --configure -a exitVMvagrant provision- Success!
Odd... I guess we'll just keep that as the official answer to whatever this problem may be. I'm guessing networking, something with the repos, who knows!
Thanks for posting what worked!
Hi,
I have the exaclty same problem on Ubuntu 14.4. I tried to do what @chrisrikli said, but I still have the problem.
Vagrant 1.8.1 ansible 2.0.1.0 drupalvm : up to date
failed: [d8vm] => (item=[u'curl', u'python-apt', u'python-pycurl', u'build-essential', u'sudo', u'unzip']) => {"failed": true, "item": ["curl", "python-apt", "python-pycurl", "build-essential", "sudo", "unzip"], "module_stderr": "", "module_stdout": "Traceback (most recent call last):\r\n File "/home/vagrant/.ansible/tmp/ansible-tmp-1467205106.47-165261602526287/apt", line 2432, in
\r\n main()\r\n File "/home/vagrant/.ansible/tmp/ansible-tmp-1467205106.47-165261602526287/apt", line 448, in main\r\n packages = p['package'].split(',')\r\nAttributeError: 'list' object has no attribute 'split'\r\n", "msg": "MODULE FAILURE", "parsed": false} to retry, use: --limit @/media/hdd/Developpement/vagrant/d8vm/provisioning/playbook.retry Ansible failed to complete successfully. Any error output should be visible above. Please fix these errors and try again.
@joelrotelli - Can you update to the latest version of Ansible (I believe 2.1.0)?
Indeed, by 2.0.1.0 I read 2.1.0.0. :)))
So now I have the latest version but I have this error :
TASK [Install extra apt packages (if any are configured).] ********************* fatal: [d8vm]: FAILED! => {"failed": true, "msg": "Unexpected templating type error occurred on ({{ extra_packages | list }}): 'NoneType' object is not iterable"} to retry, use: --limit @/media/hdd/Developpement/vagrant/d8vm/provisioning/playbook.retry
PLAY RECAP ********************************************************************* d8vm : ok=158 changed=3 unreachable=0 failed=1
Ansible failed to complete successfully. Any error output should be visible above. Please fix these errors and try again.
@joelrotelli - What do you have extra_packages set to? If you don't want any packages, it has to be set to an empty set:
extra_packages: []
If you just comment out all the lines below, then it will be an empty string instead of an array, and the | list call fails on it, causing that iterable error.
You're right, thanks a lot !
I'm having this same issue. I'm trying to use a Parallels VM box (parallels/ubuntu-14.04) though. Not sure if the matters.
@jrossol - What versions of VirtualBox and Vagrant are you running?
I too am having similar issue
TASK [Install extra apt packages (if any are configured).] *********************
failed: [my_site] (item=[u'extra_packages | list']) => {"failed": true, "item": ["extra_packages | list"], "msg": "No package matching 'extra_packages | list' is available"}
@nehajyoti04 - In your config.yml, make sure you set extra_packages: [] for that variable (if you don't want any extra packages installed.
Also, make sure you have Ansible 2.2 or later.