Is it safe to run the trellis-cli commands from inside the trellis folder

I changed the default “site” folder name to be the name of my site but after that the trellis-cli commands no longer working because trellis-cli check about the existence of the “site” folder as shown here:

but I figured that if I entered the “trellis” folder then run the trellis-cli commands it works.

So is it safe to run the trellis-cli commands from inside the “trellis” folder or not?

Yeah sorry right now it’s a limitation that the folder has to be called site.

Of course! That’s where Ansible commands would normally be run if you weren’t using trellis-cli. But again, the CLI won’t detect you’re in a project without the site folder.

But actually the trellis-cli commands works correctly without site folder if I run them within the trellis folder because it checks about this pattern before, to detect if i am in a project:

Is that right ?

Yeah that’s right sorry :sweat_smile: It will work directly in any trellis folder.

I’m probably going to remove that site check entirely which will make this more flexible for other setups like yours. I realized it’s not doing anything functional; it was originally meant to cut down on false positives but detecting a “trellis” folder with 1) group_vars configs and 2) a .trellis config dir is enough on its own.

1 Like