-
Notifications
You must be signed in to change notification settings - Fork 149
/
Copy pathconfig.yml
136 lines (128 loc) · 5.2 KB
/
config.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
imports:
- { resource: default_parameters.yml }
- { resource: parameters.yml }
- { resource: security.yml }
- { resource: env/generic.php }
- { resource: env/platformsh.php }
# Configuration for Database connection, can have several connections used by eZ Repositories in ezplatform.yml
doctrine:
dbal:
connections:
default:
driver: "%database_driver%"
host: "%database_host%"
port: "%database_port%"
user: "%database_user%"
password: "%database_password%"
dbname: "%database_name%"
charset: UTF8
# Base configuration for Solr, for more options see: https://doc.ez.no/display/EZP/Solr+Search+Engine+Bundle
# Can have several connections used by each eZ Repositories in ezplatform.yml
ez_search_engine_solr:
endpoints:
endpoint0:
dsn: "%solr_dsn%"
core: "%solr_core%"
connections:
default:
entry_endpoints:
- endpoint0
mapping:
default: endpoint0
# Stash is used for persistence cache in eZ Repository
# Can have several caches used by different eZ Repositories in ezplatform.yml, must be one per database
stash:
caches:
default:
drivers:
# When using multiple webservers, you must use Memcache or Redis to share the cache
# For single web server Apc, Memcached and Redis will give you better performance under editing load
- FileSystem
inMemory: true
registerDoctrineAdapter: false
# On Windows, using FileSystem, to avoid hitting filesystem limitations
# you need to change the keyHashFunction used to generate cache directories to "crc32"
# FileSystem:
# keyHashFunction: crc32
# Disable tracking of cache values to avoid large disk use when using web profiler
tracking_values: false
framework:
esi: ~
translator: { fallback: '%locale_fallback%' }
secret: '%secret%'
router:
resource: '%kernel.root_dir%/config/routing.yml'
strict_requirements: ~
csrf_protection: ~
form:
csrf_protection:
enabled: true
# Note: changing this will break legacy extensions that rely on the default name to alter AJAX requests
# See https://jira.ez.no/browse/EZP-20783
field_name: ezxform_token
validation: { enable_annotations: true }
#serializer: { enable_annotations: true }
# Place "eztpl" engine first intentionally if you setup use with legacy bridge.
# This is to avoid template name parsing with Twig engine, refusing specific characters
# which are valid with legacy tpl files.
templating:
engines: ['twig']
#assets_version: SomeVersionScheme
default_locale: '%locale_fallback%'
trusted_hosts: ~
session:
# https://symfony.com/doc/current/reference/configuration/framework.html#handler-id
# handler_id set to null will use default session handler from php.ini
handler_id: '%ezplatform.session.handler_id%'
# Note: eZ Publish also allows session name and session cookie configuration to be per SiteAccess, by
# default session name will be set to "eZSESSID{siteaccess_hash}" (unique session name per siteaccess)
# Further reading on sessions: http://doc.ezplatform.com/en/master/guide/sessions/
fragments: ~
http_method_override: true
# Twig Configuration
twig:
debug: '%kernel.debug%'
strict_variables: '%kernel.debug%'
# Assetic Configuration
assetic:
debug: '%kernel.debug%'
use_controller: '%kernel.debug%'
bundles: []
#java: /usr/bin/java
filters:
cssrewrite: ~
#closure:
# jar: "%kernel.root_dir%/Resources/java/compiler.jar"
#yui_css:
# jar: "%kernel.root_dir%/Resources/java/yuicompressor-2.4.7.jar"
# Swiftmailer Configuration
swiftmailer:
transport: '%mailer_transport%'
host: '%mailer_host%'
username: '%mailer_user%'
password: '%mailer_password%'
spool: { type: memory }
# FOSHttpCache Configuration
fos_http_cache:
cache_control:
rules:
# Make sure already cacheable (fresh) responses from eZ Platform which are errors/redirect gets lower ttl (then default_ttl)
-
match:
match_response: "response.isFresh() && ( response.isServerError() || response.isClientError() || response.isRedirect() )"
headers:
overwrite: true
cache_control:
max_age: 5
s_maxage: 20
# Example of performance tuning, force TTL on 404 pages to avoid crawlers / ... taking to much load
# Should not be set to high, as cached 404's can cause issues for future routes, url aliases, wildcards, ..
-
match:
match_response: "!response.isFresh() && response.isNotFound()"
headers:
overwrite: true
cache_control:
public: true
max_age: 0
s_maxage: 20