Message-ID: <1377068194.3234.1485852474491.JavaMail.confluence@ip-10-127-227-164> Subject: Exported From Confluence MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_Part_3233_320746839.1485852474491" ------=_Part_3233_320746839.1485852474491 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Location: file:///C:/exported.html Using environments

Using environments

Environment configuration as provided by Symfony is enhanced in = eZ Platform to allow specifying this in the virtual host configuration.
= You can configure several environments, from production, development or sta= ging, even if for each one of them you need to use different configuration = sets.

Web server configuratio= n

For example, using Apache, in the VirtualHost example in doc/apache2/ in your insta= ll, the required VirtualHost configurations have been already = included. You can switch to the desired environment by setting the EN= VIRONMENT environment variable to "prod", "dev" or other custom value, as you can see in the following example:

=20
# Environment.
# Possible values: "prod" and "dev" out-of-the-box, other values possible w=
ith proper configuration
# Defaults to "prod" if omitted (uses SetEnvIf so value can be used in rewr=
ite rules)
SetEnvIf Request_URI ".*" SYMFONY_ENV=3D"prod"
=20

Configuration

If you want to use a custom environment (something else then "prod= " and "dev") the next step is to create the dedicated c= onfiguration files for your environment:

The name used as <env_name>= will be the one that can be used as value of the ENVIRONMENT = environment variable.

Those files must import the main configuration file, just like the defau= lt config_dev.yml already does. Here's an example:

=20
imports:
    - { resource: config.yml }
=20

This allows you to override settings defined in the main configuration f= ile, depending on your environment (like the DB settings or any other setti= ng you may want to override).

------=_Part_3233_320746839.1485852474491--