Message-ID: <37846060.3666.1485854715729.JavaMail.confluence@ip-10-127-227-164> Subject: Exported From Confluence MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_Part_3665_2082164565.1485854715729" ------=_Part_3665_2082164565.1485854715729 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Location: file:///C:/exported.html PHP's built-in server

PHP's built-in server

=20
=20
=20
=20

Description

PHP, in 5.4 and later, comes with a built-in webserver for development purposes. This is very handy, as i= t allows you to kickstart development quickly, avoidi= ng having to install and configure Apache / Nginx. All = you need here is PHP 5.4+ with command line binary.

Usage

Symfony comes with a wrapper script for booting the built-in webserver:&= nbsp;server:run. It's a nice shortcut as it will correctly set = the web root depending on your configuration, and with eZ Platform it can b= e used as is.

Use this command for local development purpose only! DO NOT use this on production servers, the use of --env=3Dprod below is just showcasing that you can use the command both with Symfony'= s dev and prod environment depending on if you are debugging or just testin= g out your application locally.

Examples

The following example will start the webserver on http://127.0.0.1:= 8000 on your machine, in Symfony dev environment for debug use:

Debug example
=20
php app/console server:run
=20

The following example will start the webserver on http://localhost= :8000 on your machine, in Symfony prod environment for demo/testin= g use:

Testing/Demo example
=20
php app/console server:run --env=3Dprod localhost:8000
=20

 

Help with the com= mand

As with any Symfony command, you may execute the command with a -h= flag to get up-to-date help text for the command:

Help info example
=20
php app/console server:run -h
=20

 

 

=20
=20 =20
=20
------=_Part_3665_2082164565.1485854715729--