Tideways Installation

Introduction

If you would like to use Tideways, a very comprehensive PHP profiler, on your website and/or online store, our installation guide will show you how to install and configure the service on your server.


Prerequisites

  • creoline server
  • Active Tideways license



Installation on Managed Servers

To install Tideways on managed servers, please contact our support team so that we can handle the installation and configuration of Tideways for you.



Installation on Unmanaged Servers

To install Tideways on Debian and Ubuntu servers, you need an active root SSH connection to begin the installation.


First, you must install the Tideways PHP service and the Tideways daemon. Install both packages using the following SSH commands:


echo 'deb [signed-by=/usr/share/keyrings/tideways.gpg] https://packages.tideways.com/apt-packages-main any-version main' | tee /etc/apt/sources.list.d/tideways.list > /dev/null


wget -qO - 'https://packages.tideways.com/key.gpg' | gpg --dearmor | tee /usr/share/keyrings/tideways.gpg > /dev/null


 apt-get update && apt-get install tideways-php tideways-daemon


After installation, Tideways must be configured with your API key and the desired environment (Production, Stage, etc.). We’ll show you how to successfully configure Tideways in the following steps for Plesk, PHP-FPM, and Mod PHP (Apache2).


Configuration in Plesk

To configure Tideways in Plesk, log in to your Plesk Control Panel and navigate to Website → PHP Settings → Additional Instructions



You can find your Tideways API key under Tideways → Project → Setup → php.ini

The configuration looks like this:


Apache

SetEnv TIDEWAYS_APIKEY XXXXXXXXXXXXXXX
SetEnv TIDEWAYS_SAMPLERATE 25


NGINX

location / {
    ...
    fastcgi_param TIDEWAYS_APIKEY XXXXXXXXXXXXXXX;
    fastcgi_param TIDEWAYS_SAMPLERATE 25;
 ...
}


Paste this into the additional configuration section in Plesk so that the result looks like this:



After installation, you can check whether Tideways is already collecting data; please wait 60 seconds so that Tideways can collect the data.



Configuration under PHP-FPM

To configure Tideways under PHP-FPM, you need an active SSH connection as the root user to log in to the desired server.


Once connected, open the zz-creoline.ini file with nano or vim and edit the file as instructed.


Please note that the instructions in zz-creoline.ini should not be changed; simply add your Tideways API key here.


nano /etc/php/8.2/fpm/conf.d/zz-creoline.ini

You must add the following lines to zz-creoline.ini:

tideways.api_key=XXXXXXXXXXXXXXXXXX
tideways.sample_rate=25


After configuring the file, you should reload the PHP-FPM service by running the following commands:

# Config test
php-fpm8.2 --test

# Reload
systemctl reload php8.2-fpm.service



Configuration with Mod PHP (Apache2)


If you are installing Tideways on Apache2, log in as the root user via SSH to the server for which you want to analyze data with Tideways.


First, you must enter the Tideways API key. To do this, use the zz-creoline.ini file. If the file does not yet exist, you can create it with the following command:

nano /etc/php/8.2/fpm/conf.d/zz-creoline.ini


You must add the following lines to the zz-creoline.ini file:

tideways.api_key=XXXXXXXXXXXXXXXXXX
tideways.sample_rate=25


After configuring the settings, you should reload the PHP-FPM service by running the following commands:

# Config test
php-fpm8.2 --test

# Reload
systemctl reload php8.2-fpm.service



Setting Up the Environment

In Tideways, you can configure multiple environments; this is done via the included tideways-daemon file.



The file is located at /etc/default/tideways-daemon and can be edited with nano or vim. To edit the file, you can use the following command:


nano /etc/default/tideways-daemon


The file contents should look something like this:

TIDEWAYS_DAEMON_EXTRA="--env=staging"


If you want to display your staging environment, use --env=staging; if you’re using Tideways in your production environment, you must enter --env=production here.


After a restart, the data will be displayed in the specified environment.