[Doc confusion] Correct Way to set up custom projects

Kinda lost on how to create custom projects with Trellis/Ansible.

Following the docs, I change the vault.yaml and wordpress_sitesunder development to reflect the my site. personal.dev etc.

However when I run vagrant provision I get

---------------------------------------------------
You are running composer with xdebug enabled. This has a major impact on
runtime performance. See https://getcomposer.org/xdebug
Running composer as root/super user is highly discouraged as packages,
plugins and scripts cannot always be trusted
Composer could not find a composer.json file in /srv/www/personal.dev/current
To initialize a project, please create a composer.json file as described in
the https://getcomposer.org/ "Getting Started" section
failed: [default] (item=personal.dev) => {"changed": true, "cmd": ["composer", "install"], "delta": "0:00:00.110487", "end": "2016-07-03 15:10:07.343974", "failed": true, "item": "personal.dev", "rc": 1, "start": "2016-07-03 15:10:07.233487", "stderr": "You are running composer with xdebug enabled. This has a major impact on runtime performance. See https://getcomposer.org/xdebug\nRunning composer as root/super user is highly discouraged as packages, plugins and scripts cannot always be trusted\nComposer could not find a composer.json file in /srv/www/personal.dev/current\nTo initialize a project, please create a composer.json file as described in the https://getcomposer.org/ \"Getting Started\" section", "stdout": "", "stdout_lines": [], "warnings": []}
```

Can we update the docs to better reflect how to do it properly. What other files are missing?

I’m going to assume you’re using Vagrant 1.8.4. It has a bug which causes this.

Trellis requires 1.8.1 so you can downgrade to that version.

https://releases.hashicorp.com/vagrant/1.8.1/

That was it for the most part but redoing the above now gets me a 404 on the URL

You may need to run $ vagrant destroy && vagrant up to destroy remnants of the failed first provisioning and reprovision with the correct Vagrant version.

I’ve had that happen before and the issue was just that the development url hadn’t been added to my hosts file.

Running vagrant hostmanager usually does the trick for me.

2 Likes

Yep, this solved the issue.

Thanks for your help folks.