docs community blog github
Edit

PHP Buildpack Reference

This reference documentation offers an in-depth description of the behavior and configuration options of the Paketo PHP Buildpack. For explanations of how to use the buildpack for several common use-cases, see the Paketo PHP Buildpack How To documentation.

Supported Dependencies

The PHP Paketo Buildpack supports several versions of PHP. For more details on the specific versions supported in a given buildpack version, see the release notes.

Buildpack-Set Environment Variables

The PHP CNB sets a number of environment variables during the build and launch phases of the app lifecycle. The sections below describe each environment variable and its impact on your app.

APP_ROOT

  • Set by: httpd buildpack
  • Phases: launch
  • Value: path of app source

SERVER_ROOT

  • Set by: httpd buildpack
  • Phases: launch
  • Value: path of the httpd installation

MIBDIRS

PATH

  • Set by: php-dist buildpack
  • Phases: build and launch
  • Value: path to the php executable

PHP_API

  • Set by: php-dist buildpack
  • Phases: build and launch
  • Value: internl api version (YYYYMMDD)

PHP_EXTENSION_DIR

  • Set by: php-dist buildpack
  • Phases: build and launch
  • Value: location of directory with dynamic libraries for extensions

PHP_HOME

  • Set by: php-dist buildpack
  • Phases: build and launch
  • Value: location of php installation

PHP_INI_SCAN_DIR

  • Set by: php-web buildpack
  • Phases: build and launch
  • Value: <APP-ROOT>/.php.ini.d
Edit

Last modified: September 21, 2021