Windows Compliance - nvm


I wanted to share my experience with setting up Trellis on Windows: as a matter of fact, 99% of the software components ARE natively supported by Windows (no WSL required). The only one that is not is nvm (for node versions management). Any chance its usage can be avoided? It seems to me that it is not significantly important to support multiple versions of node, and that it is instead a workaround to simplify setup and avoid clashing with pre-existent environment installation. Any thoughts on that by the Roots guys? :slight_smile:

The problem we - Windows users - experience is that the interaction between WSL and the native filesystem is quite unconfortable (let alone performances might reduce significantly).

Trellis doesn’t require nvm, Sage however, does.
But, nvm is only used for installing/managing multiple version of nodejs. You can just install nodejs in Windows, but you can’t switch nodejs versions easily.

If you find Trellis hard to use for your local dev environment, I can recommend

You can’t get server-parity (or how it’s called) with lando however, but you might not need that.

I use Sage + Bedrock on WSL (1) on Windows 10, including nvm for ensuring a specific node version (which can be important for deterministic build). It works great and fast enough for me.

I use Sage + Bedrock on Windows 10 without WSL and works fine aswell. I think I will retry with Trellis to recheck the issues… perhaps my issues were related to the steps from the official guide which assumes WSL. It is worth noting that a nvm-windows project seems to exist by 3d party devs.


My understanding, based on this FAQ in the Ansible docs, is that Ansible, and therefore Trellis, can’t run natively in Windows. Can you elaborate on how you got Trellis working in a Windows environment?

1 Like

I run ansible on WSL (1) without any issues by having ansible installed using pip.
Hm, isn’t WSL technically “Windows” but rather an elaborate abstraction system, even WSL 1?

The OP was talking about running Trellis on Windows without the use of WSL, which so far as I’m aware is not possible.


Perhaps I wasn’t clear, I didn’t make it work yet. As a matter of fact, I read of some people installing Ansible via pip by pulling the development repo, but I believe it’s not needed. It seems that Ansible is not a direct dependency of trellis, but rather a Vagrant one. Nevertheless Vagrant does work on Windows (not sure how Ansible is used), I’ll try to run some more experiments and let you know. In case you have some specific insights on that, they are more than welcome :slight_smile:

I am not really using Vagrant but Docker. Ansible works fine on Windows, WSL (1).

Early tests seem to confirm the assumption, I’ll try to update the post when I have a full environment up and running.

Trellis is essentially a set of Ansible playbooks. Without Ansible, Trellis doesn’t really exist. You can vagrant up the Vagrantfile that comes with it, as you’ve done, but without Ansible you won’t be able to use Trellis to provision remote servers or deploy your site. If you just want a VM, you don’t need Trellis, you just need a Vagrantfile to describe the VM you want.

1 Like

You’re right, I was just realising this. I’m afraid I will put aside Trellis for some time, it also doesn’t seem right for aws deployments, which I’m interested in :slight_smile:

This topic was automatically closed after 42 days. New replies are no longer allowed.