After using Valet + Bedrock/Sage + Capistrano the last few years I recently ditched valet and started using Lando for all local dev after the great guide by @knowler and I 99% love it! It works fantastic 80% of the time but i’m having a few tiny issues that seem to crop up after normal usage and wanted to see if anyone else has run across them:
#1 localhost:3000 automatically redirects to the Site URL which never allows the site to be viewed on at the localhost URL rendering watch useless. It doesn’t happen immediately upon creating a fresh lando + bedrock + sage install but instead just seems to happen at some point. I’m not positive but I think it may start happening after running
lando rebuild(again not certain of this)
I’ve tried the following with no avail:
- Changing the port number in .lando.yml and config.json
- Clearing both the browser and DNS cache (along with disabling dnscrypt)
- Restarting docker and running
- Installing/Activating a fresh sage 9.0.9
I end up resorting to running
lando yarn build after each save then manually refreshing the page as the only thing that seemed to fix it is rather cumbersome… running
lando destroy (after backing up the database) removing vendor and node_modules directories and reinstalling.
Anyways, here’s my .lando.yml:
name: justiceforkevinbrame recipe: wordpress proxy: theme: - localhost:8080 phpmyadmin: - phpmyadmin.justiceforkevinbrame.lndo.site mailhog: - mail.justiceforkevinbrame.lndo.site config: php: '7.2' via: nginx webroot: web database: mariadb xdebug: true services: appserver: type: php:7.2 database: type: mariadb theme: type: node overrides: services: ports: - 8080:8080 phpmyadmin: type: phpmyadmin mailhog: type: mailhog hogfrom: - appserver tooling: yarn: service: theme composer: service: appserver description: Run composer commands cmd: composer --ansi php: service: appserver mysql: user: root service: database description: Drop into a MySQL shell sendmail: service: appserver cmd: /usr/local/bin/mhsendmail alert: service: appserver cmd: php /app/mail.php
#2 Consistently in Sage 9.0.7, while runing webpack watch, the CSS stops updating in the browser once you try to save any change that results in a stylelint error …even after correcting the error. Webpack says it has recompiled but the browser wont show updated styles until stopping and restarting webpack watch.
Any thoughts or ideas appreciated.