How do I set Environment Variables in PHP?

Environment Variables in PHP are as below : 


Apache:

 

Variable

Value Example

Description

APACHE_VERSION

2.4.6

A version of the running Apache server (informational)

PHP_VERSION

7.2.1

A version of the running PHP engine (informational)

WEBROOT

/var/www/webroot

Sets a path to the directory for application deployment

 

NGINX:

 

Variable

Value Example

Description

NGINX_VERSION

1.12.2

A version of the running NGINX server (informational)

PHP_VERSION

7.2.1

A version of the running PHP engine (informational)

WEBROOT

/var/www/webroot

Sets a path to the directory for application deployment

PHPFPM_MAX_CHILDREN

8

Sets a number of child worker processes for PHP-FPM. Is equal to the number of CPU cores available for container by default (but no less than 2)

 


Was this article helpful?

mood_bad Dislike 0
mood Like 1
visibility Views: 13808