I am new to trellis, but I have been using Bedrock for a while now, and I am trying to get it work on both Silicon and Intel.
I would like to use it for local development at least and maybe replacing DeployHQ.
But let’s focus on silicon, here is the error I get after installing and creating a new site with trellis-cli and doing trellis provision development
TASK [Gathering Facts] *********************************************************[ERROR]: Task failed: Failed to connect to the host via ssh: [email protected]: Permission denied (publickey).
Task failed.
<<< caused by >>>
Failed to connect to the host via ssh: [email protected]: Permission denied (publickey).
fatal: [default]: UNREACHABLE! => {“changed”: false, “msg”: “Task failed: Failed to connect to the host via ssh: [email protected]: Permission denied (publickey).”, “unreachable”: true}
Any help will be appreciated, many thanks.
Using :
trellis v1.14.0
lima v1.2.1
Sequoia 15.6.1
Weird. It looks like your SSH key isn’t working with the VM. Have you removed any ssh keys by any chance? If not, I’d probably just delete the VM and create a new one, then import the database again.
I also tried this workaround without luck on trellis provision development.
The vm actually starts (make a mistake in my first post) and is visible using limactl list.
After some time of research, I could get it working by forcing the trellis version to the last one : trellis new --trellis-version v1.26.0 mywebsite.com
I don’t know why, brew is not installing the last version by default.
Also, when using v1.26.0, after running trellis vm start I am still not able to connect to the server using ssh.
I need to add ansible_ssh_private_key_file=~/.lima/_config/userto trellis/.trellis/lima/inventory file.
Not sure if it’s a known issue.
Funnily enough I just saw the exact same sequence of errors when trying to provision a new droplet from an existing Trellis 1.25 environment — permission denied and then loop value must resolve to a list. Updating to Trellis 1.26.1 (and running trellis init again) fixed it for me as well, so thank you for posting this!