Vagrant WordPress Install does not work

I am following [this tutorial](https://premium.wpmudev.org/blog/vagrant-wordpress-test-environment/?nhp=b&utm_expid=3606929-87.FQUx5sKvRhKbhK_8_C59WQ.1) to set up WordPress with vagrant. But it does not seem to work.

I get the following:

==> default: gpg:
==> default: keyring `/tmp/tmpJZaDWh/secring.gpg' created
==> default: gpg:
==> default: keyring `/tmp/tmpJZaDWh/pubring.gpg' created
==> default: gpg:
==> default: requesting key E5267A6C from hkp server keyserver.ubuntu.com
==> default: gpg:
==> default: /tmp/tmpJZaDWh/trustdb.gpg: trustdb created
==> default: gpg:
==> default: key E5267A6C: public key "Launchpad PPA for Ond\xc5\x99ej Sur?" imported
==> default: gpg:
==> default: Total number processed: 1
==> default: gpg:
==> default: imported: 1
==> default: (RSA: 1)

and then:

==> default: E
==> default: :
==> default: Unable to correct problems, you have held broken packages.
==> default: tee:
==> default: /etc/php5/mods-available/xdebug.ini
==> default: : No such file or directory
==> default: xdebug.scream=1
==> default: xdebug.cli_color=1
==> default: xdebug.show_local_vars=1
==> default: sudo
==> default: :
==> default: a2enmod: command not found
==> default: sed: can't read /etc/php5/apache2/php.ini: No such file or directory
==> default: sed: can't read /etc/php5/apache2/php.ini: No such file or directory
==> default: sed: can't read /etc/php5/cli/php.ini: No such file or directory
==> default: apache2: unrecognized service
==> default: /tmp/vagrant-shell: line 26: php: command not found
==> default: mv:
==> default: cannot stat `composer.phar'
==> default: : No such file or directory
The SSH command responded with a non-zero exit status. Vagrant
assumes that this means the command failed. The output for this command
should be in the log above. Please read the output to determine what
went wrong.

I do not know what this means, really, or where the problem could lie. Vagrant does work though, I have been able to start up a vagrant box before without errors. It is just in the context of the above mentioned tutorial that I run into problems.

2 thoughts on “Vagrant WordPress Install does not work”

  1. > Launchpad PPA for Ond\xc5\x99ej Sur?

    This looks like you copy/pasted the install.sh script from html, resulting in non-ascii characters messing up the script. Copy/paste the script from ‘raw’ (the code box has a ‘view raw’ link below right) and try again.

    If that doesn’t fix it, `vagrant destroy -f; vagrant up –no-provision` the box, then `vagrant ssh` and `sudo su -` and run the script line by line to see where it fails.

    On a side note, the tutorial asks you to copy/paste and run shortened urls on your workstation. By just blindly running that you could install anything from legitimate wordpress stuff to a botnet. Might not be a big deal, but it would be reason enough for me to skip the tutorial altogether.

    Reply

Leave a Comment