geerlingguy.php-xhprof
Ansible Role: PHP-XHProf
This role installs PHP XHProf on Linux servers.
Note: The XHProf extension hasn't been actively developed since Facebook stopped updating it around 2015. If you need to work with the latest PHP versions, consider using a well-maintained version called Tideways. There's also an Ansible role for Tideways—check out
geerlingguy.php-tideways
.
Requirements
No special requirements.
Role Variables
Here are the variables you can use, along with their default values (check defaults/main.yml
for more):
workspace
: /rootThis is where XHProf setup files will be downloaded and built.
xhprof_version
: "2.1.2"This specifies the version of XHProf to download.
xhprof_download_url
: https://github.com/longxinH/xhprof/archive/v{{ xhprof_version }}.zipxhprof_download_folder_name
: xhprof-{{ xhprof_version }}This is the URL from which XHProf will be downloaded.
xhprof_output_dir
: /tmpThis is where XHProf run results will be stored.
php_xhprof_lib_dir
: /usr/share/php/xhprof_libHere is where the XHProf PHP library is stored.
php_xhprof_html_dir
: /usr/share/php/xhprof_htmlThis is the directory for the XHProf User Interface (UI).
Dependencies
- geerlingguy.php
Example Playbook
Here’s how to use it in your playbook:
- hosts: webservers
roles:
- geerlingguy.php-xhprof
License
MIT / BSD
Author Information
This role was created in 2014 by Jeff Geerling, who wrote Ansible for DevOps.
ansible-galaxy install geerlingguy.php-xhprof