Challenges with Trellis and Lima Setup in Radicle

Recently, we started using Radicle for our projects. Initially, we attempted to use Trellis with Lima, but unfortunately, we couldn’t get it to work as expected. Then, we switched to Lando, which worked fine for a while. However, after some time, I started encountering errors with commands, specifically a “Segmentation fault” error. I had previously posted about this issue, but my colleague didn’t experience the same problem. In an attempt to resolve it, I set up Radicle locally with WP, which temporarily solved the issue as it saved time. Meanwhile, my colleague continued to use Lando, but eventually faced the same error with commands, leading us both to switch back to local WP.

Now, as we embark on a new project, we decided to give Trellis another try. However, upon revisiting it, I encountered various problems. It’s worth mentioning that I am using an M1 Pro Mac, while my colleague is using an Intel Mac.

Our goal is to utilize Trellis with Lima in Radicle. Initially, I followed the steps of running “php .radicle-setup/trellis.php,” then “cd trellis/,” and finally “trellis init.” Since we were using Lima, I needed to execute “trellis vm start.” However, during the startup process, we encountered different errors with each attempt.

First, we encountered a failure on the task “Checking essentials.” I commented out this task in the main.yml file, which allowed the process to proceed further. However, it got stuck at the “fail2ban” task. I re-enabled the “Checking essentials” task in main.yml, which allowed us to proceed. Nevertheless, we kept encountering different errors in subsequent stages, making it challenging to debug and seek assistance.

We would greatly appreciate any ideas or suggestions on what might be causing these issues or how to resolve them. Thank you in advance for your help and input.

Hi there!

Re: The Lando segmentation fault issue — this sounds like a Docker problem. I’ve ran into it once before and was able to solve it by clearing out my existing Docker images and volumes and then rebuilding the app.

Re: Trellis/Lima — I had an issue this week where after a reboot I suddenly was having issues with both Vagrant and Lima based Trellis installs. I was able to get back up and running after updating my OS, updating my Vagrant box, updating Parallels, and finally manually clearing out some Lima specific hosts entries.

We can try and troubleshoot this if you can provide the full log output.

I managed to get the environment working by deleting it with “trellis vm delete” and recreating it. However, I’d like it to work quickly, as these attempts can sometimes take up a lot of time. My preference is to get the environment working within 1 or 2 tries. I tried setting up multiple environments, and here are the results: out of 6 test environments, it took an average of 5 attempts to get them working so I could access the site. There were 2 outliers with 10 and 7 attempts. It seems that the issues often occur during “Install MySQL client” and “common: restart journald.” Additionally, I encountered failures with tasks like “Add MariaDB APT key,” “common: restart memcached,” and “composer: Update Composer to the latest version (if configured).”

Here a gist with the debug logs of one environment.