Skip to content
A Chassis extension to install and setup XHGui on your server
Puppet HTML PHP
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
modules/chassis_xhgui
xhgui @ f426886
.gitmodules
.travis.yml
README.md
chassis.yaml
local-config.php

README.md

XHGui

A Chassis extension to install and configure XHGui on your Chassis server. This extension also has XHProf as a dependency so it will be installed and configured automatically as well.

Installation

  1. Add this extension to your extensions directory git clone --recursive git@github.com:Chassis/Chassis_XHGui.git extensions/chassis_xhgui
  2. Note: The folder that you clone into must be called chassis_xhgui.
  3. Run vagrant provision.

Alternative Installation

  1. Add - chassis/chassis_xhgui to your extensions in yaml files. e.g.
    extensions:
    - chassis/chassis_xhgui
    
  2. Run vagrant provision.

Please note: vagrant provision can take quite a few minutes due to the amount of Composer dependencies in XHGui. So when you see the provisioning process taking a long time on Service[php7.0-fpm] please be patient as this is the stage where Composer dependencies are being installed.

Usage

Browse to http://vagrant.local/xhgui in a browser. If you have a custom host hame it will be http://<yourhostname>.local/xghui.

If you're using custom paths you'll need to change the URL to add your custom base. For example: If you've Chassis located in a chassis folder then the URL will be http://vagrant.local/chassis/xhgui or http://<yourhostname>.local/chassis/xghui.

Controlling When the Profiler Runs

This extension enables the XHProf profiler for every request. You can control whether or not the profiler runs from the profiler.enable callback function that is contained within the extensions/chassis_xhgui/xhgui/config/config.php file.

From this callback function you can perform logic based on $_SERVER values, php_sapi_name(), etc, but remember that WordPress has not loaded at this point so you can't use any function that WordPress provides.

'profiler.enable' => function() {
	if ( false !== strpos( $_SERVER['REQUEST_URI'], 'wp-admin/' ) ) {
		// Disable the profiler for requests to wp-admin:
		return false;
	}

	// Enable the profiler for all other requests:
	return true;
},

Further information about configuring the profiler and other XHGUI options can be found in the XHGUI repo documentation.

Uninstallation

  1. Add - chassis/chassis_xhgui to your disabled_extensions in yaml files. e.g.
    disabled_extensions:
    - chassis/chassis_xhgui
    
  2. Run vagrant provision.

Screenshots

Recent Runs

Profile Data

Call Graph

Flame Graph

Function Calls

You can’t perform that action at this time.