# Remote Server Setup on Windows

**URL:** https://discourse.roots.io/t/remote-server-setup-on-windows/5594
**Category:** trellis
**Created:** 2015-12-29T19:36:41Z
**Posts:** 5

## Post 1 by @Groques — 2015-12-29T19:36:41Z

Whenever I run `ansible-playbook server.yml -e env=production` in my vagrant box I get the error.

> ERROR: problem running /vagrant/hosts/development --list ([Errno 8] Exec format error)

My suspicion is it has something to do with Windows, shared folders, and permission issues which is alluded to here [https://github.com/mitchellh/vagrant/issues/713](https://github.com/mitchellh/vagrant/issues/713).

@DemaniClassic had a working solution before the “[Refactor hosts files](https://github.com/roots/trellis/commit/40cdb5e75f4b83090df3405d3d63829c81d763f0)” commit.

[https://discourse.roots.io/t/deploying-from-windows/4434/4](https://discourse.roots.io/t/deploying-from-windows/4434/4)

How can I replicate DemaniClassic’s solution with the new update to the hosts files?

---

## Post 2 by @QWp6t — 2015-12-29T19:49:17Z

In your Vagrantfile, you can try adding the following:

```
config.vm.synced_folder File.join(ANSIBLE_PATH, 'hosts'), '/vagrant/hosts', owner: 'vagrant', group: 'www-data', mount_options: ['dmode=755', 'fmode=644']
```

I think that will remove `+x` from `/vagrant/hosts/*`

---

## Post 3 by @Groques — 2015-12-30T11:00:41Z

I added

> config.vm.synced\_folder File.join(ANSIBLE\_PATH, ‘hosts’), ‘/vagrant/hosts’, owner: ‘vagrant’, group: ‘www-data’, mount\_options: [‘dmode=755’, ‘fmode=644’]

in my vagrantfile and it worked! @QWp6t Thank you so much.

---

## Post 4 by @DemaniClassic — 2016-01-11T22:44:21Z

Thanks! Worked for me

---

## Post 5 by @fullyint — 2016-01-12T02:07:31Z

[roots/trellis#460](https://github.com/roots/trellis/pull/460) proposes to add @QWp6t’s solution into Trellis. Could use a few Windows users to test and confirm that it works for their setup.
