Heroku installation
Last updated 2024-02-20
IMPORTANT
This guide only applies to Next-Gen WAF customers with access to the Next-Gen WAF control panel. If you have access to the Next-Gen WAF product in the Fastly control panel, you can only deploy the Next-Gen WAF with the Edge WAF deployment method.
The Next-Gen WAF agent can be deployed with Heroku. The installation process is compatible with any of the language buildpacks.
Prerequisites
Copy the agent keys for the site that you want the agent to be able to access. You will use the agent keys when configuring the Next-Gen WAF agent package.Installation
Log in to Heroku.
$ heroku loginAdd the Signal Sciences buildpack to your application settings.
$ heroku buildpacks:add --index 1 https://dl.signalsciences.net/sigsci-heroku-buildpack/sigsci-heroku-buildpack_latest.tgzNOTE
The Signal Sciences buildpack must run first or before your application's primary buildpack.
In your
Procfile
file, addsigsci/bin/sigsci-start
so it precedes your existing start command:web: sigsci/bin/sigsci-start YOUR-APPLICATION'S-START-COMMANDExample:
web: sigsci/bin/sigsci-start node index.jsAdd the Next-Gen WAF agent keys to your application's environment variables.
$ heroku config:set SIGSCI_ACCESSKEYID=access-key-goes-here$ heroku config:set SIGSCI_SECRETACCESSKEY=secret-key-goes-hereDeploy your application. Heroku applications are typically deployed with the following commands:
$ git add .$ git commit -m "my comment here"$ git push heroku main
Configuration
Each time you deploy your application, Heroku will automatically assign a new random name for the agent. An agent name for each deployment can be specified by setting the
SIGSCI_SERVER_HOSTNAME
environment variable:$ heroku config:set SIGSCI_SERVER_HOSTNAME=agent-nameAgent access logging can be enabled by setting the
SIGSCI_REVERSE_PROXY_ACCESSLOG
environment variable:$ heroku config:set SIGSCI_REVERSE_PROXY_ACCESSLOG /tmp/sigsci_access.logThe buildpack will install the latest version of the Next-Gen WAF agent by default. You can specify which agent version to install by setting the
SIGSCI_AGENT_VERSION
environment variable:$ heroku config:set SIGSCI_AGENT_VERSION=1.15.3
Additional configuration options are listed on the agent configuration page.
Do not use this form to send sensitive information. If you need assistance, contact support. This form is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.