Development

Tideways and Xhgui using Lando

While I prefer using Valet+ for my Drupal development, I have been asked a few times to share my Lando + Tideways setup. I can’t go into too many details at this point, because it’s been a while since I’ve used this, but here’s my setup. I’ve included some documentation within some of the files (especially at the bottom of .lando.yml).

You can see some explanation and screenshots of Tideways and Xhgui in my Tideways and Xhgui using Dev Desktop post if you need a bit of an introduction. Also, you may be interested in seeing how I got Tideways running with Valet+.

This example is for Drupal 7. You can rework it easily to work with Drupal 8. The .conf may not be required in either case.

 

Folder/File Structure

 

.lando.yml

UPDATE June 4, 2019: If you’re on a new version of Lando you may have to shuffle around your overrides a bit: https://docs.devwithlando.io/guides/updating-to-rc2.html#overrides

 

drupal7.conf

 

php.ini

 

xhgui.yml

One Comment

  • Allan Chappell

    I was following this as a guide… I noticed you added a drupal7.conf with what you said were a few overrides. I’m trying to make this happen for a d8 site so I wanted to see the differences you came up with so that I could extrapolate a configuration there…

    The diff between your config and the current lando drupal7 config is as follows.


    $ diff -u landod7.conf drupal7.conf
    --- landod7.conf 2020-09-23 16:43:41.910590077 -0500
    +++ drupal7.conf 2020-09-23 16:43:27.618215508 -0500
    @@ -2,22 +2,16 @@
    listen 80 default_server;
    listen 443 ssl;

    - server_name localhost;
    + server_name appserver;

    ssl_certificate /certs/cert.crt;
    ssl_certificate_key /certs/cert.key;
    ssl_verify_client off;

    - ssl_session_cache shared:SSL:1m;
    - ssl_session_timeout 5m;
    -
    - ssl_ciphers HIGH:!aNULL:!MD5;
    - ssl_prefer_server_ciphers on;
    -
    port_in_redirect off;
    client_max_body_size 100M;

    - root "{{LANDO_WEBROOT}}";
    + root ${LANDO_WEBROOT};

    location = /favicon.ico {
    log_not_found off;
    @@ -36,7 +30,7 @@
    deny all;
    }

    - location ~ \..*/.*\.php$ {
    + location ~ \..*/.*\.php {
    return 403;
    }

    @@ -100,11 +94,12 @@
    #fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
    #lando
    fastcgi_pass fpm:9000;
    + fastcgi_read_timeout 300;
    }

    # Fighting with Styles? This little gem is amazing.
    # location ~ ^/sites/.*/files/imagecache/ { # For Drupal = 7
    + location ~ ^/sites/.*/files/styles/ { # For Drupal >= 7
    try_files $uri @rewrite;
    }

    @@ -118,5 +113,4 @@
    expires max;
    log_not_found off;
    }
    -
    }

    me thinks the only possible big change would be in the server_name? and possible the fastcgi_read_timeout 300? and possible the location regex…

    Any thoughts?

Leave a Reply

Your email address will not be published.