Install on Heroku

Tideways can be installed on Heroku by using the PHP buildpack extension functionality that hooks into Composer.

In the first step you set an environment variable used by the PHP buildpack to discover the Tideways Composer packages:

heroku config:set HEROKU_PHP_PLATFORM_REPOSITORIES="https://s3-eu-west-1.amazonaws.com/tideways/heroku/"

If you already have another external platform repository configured then separate both urls by space.

Then modify the composer.json of your Heroku PHP project to add a dependency to ext-tideways fetched from the previously configured remote package repository:

{
    "require": {
        "php": "7.0.*",
        "ext-tideways": "@stable"
    },
    "config": {
        "platform": {
            "ext-tideways": "1.0.0"
        }
    }
}

The config.platform setting ensures that even without the extension installed on your local computer, a composer update will not complain about the missing extension.

Re-run Composer to generate the changes to a new lock file:

composer update ext-tideways --ignore-platform-reqs

Commit the changes and push your application to re-deploy:

git add composer.json composer.lock
git commit -m 'Add ext-tideways dependency to Heroku app'
git push heroku master

To enable Tideways on your Heroku app you still need to configure API Key, framework and sample rate as environment variables:

heroku config:set TIDEWAYS_APIKEY="abcdefg" TIDEWAYS_SAMPLERATE="20"

You can find your API Key for your Tideways application from the dropdown menu entry "Application Settings".

As a last step you can (optionally) enable the deploy tracking, again on the "Application Settings" screen by clicking on Heroku in the Integrations section. It will show a command to activate a deploy hook addon that looks like the following:

heroku addons:create deployhooks:http --url="https://app.tideways.io/api/events/heroku/....."
Still need help? Email [email protected]