]> Raphaël G. Git Repositories - airbundle/blob - Resources/config/packages/rapsysair.yaml
Fix zipcode default value to match form input type
[airbundle] / Resources / config / packages / rapsysair.yaml
1 # Parameters configuration
2 parameters:
3 # Google client
4 env(RAPSYSAIR_GOOGLE_CLIENT): "Ch4ng3m3!"
5 # Google project
6 env(RAPSYSAIR_GOOGLE_PROJECT): "Ch4ng3m3!"
7 # Google secret
8 env(RAPSYSAIR_GOOGLE_SECRET): "Ch4ng3m3!"
9 # Hostname
10 env(RAPSYSAIR_HOSTNAME): "Ch4ng3m3!"
11 # Scheme
12 env(RAPSYSAIR_SCHEME): "https"
13
14 # RapsysAir configuration
15 rapsysair:
16 languages:
17 en_gb: 'English'
18 fr_fr: 'French'
19 locale: 'fr_fr'
20 locales: [ 'fr_fr', 'en_gb' ]
21 logo:
22 alt: 'Libre Air logo'
23 title: 'Libre Air'
24
25 # RapsysUser configuration
26 rapsysuser:
27 # Class replacement
28 class:
29 civility: 'Rapsys\AirBundle\Entity\Civility'
30 country: 'Rapsys\AirBundle\Entity\Country'
31 dance: 'Rapsys\AirBundle\Entity\Dance'
32 group: 'Rapsys\AirBundle\Entity\Group'
33 user: 'Rapsys\AirBundle\Entity\User'
34 # Default replacement
35 default:
36 group: [ 'User' ]
37 civility: 'Mister'
38 languages: '%rapsysair.languages%'
39 locales: '%rapsysair.locales%'
40 country: 'France'
41 country_favorites: [ 'France', 'Belgium', 'Germany', 'Italy', 'Luxembourg', 'Portugal', 'Spain', 'Switzerland' ]
42 dance_favorites: [ 'Argentine Tango Ball', 'Argentine Tango Ball and class', 'Argentine Tango Ball and concert' ]
43 subscription_favorites: [ 'Milonga Raphaël' ]
44 # Route replacement
45 route:
46 index:
47 name: 'rapsysair'
48 # Translate replacement
49 translate: [ 'title.page', 'title.section', 'title.site', 'password', 'copy.by', 'copy.long', 'copy.short', 'copy.title', 'logo.alt' ]
50 # Contact replacement
51 contact:
52 address: '%rapsysair.contact.address%'
53 name: '%rapsysair.contact.name%'
54 # Context replacement
55 context:
56 copy: '%rapsysair.copy%'
57 icon: '%rapsysair.icon%'
58 logo: '%rapsysair.logo%'
59 root: '%rapsysair.root%'
60 title:
61 section: 'User'
62 site: '%rapsysair.title%'
63 # Edit replacement
64 edit:
65 field:
66 pseudonym: false
67 route:
68 index: 'root'
69 view:
70 edit: 'Rapsys\AirBundle\Form\RegisterType'
71 name: '@RapsysAir/form/edit.html.twig'
72 context:
73 title:
74 page: 'Modify account'
75 password: 'Modify password'
76 # Login replacement
77 login:
78 route:
79 index: 'root'
80 view:
81 name: '@RapsysAir/form/login.html.twig'
82 context:
83 title:
84 page: 'Login'
85 # Recover replacement
86 recover:
87 route:
88 index: 'root'
89 recover: 'recover_url'
90 view:
91 name: '@RapsysAir/form/recover.html.twig'
92 context:
93 title:
94 page: 'Recover'
95 mail:
96 subject: 'Welcome back %%recipient_name%% to %%site.title%%'
97 html: '@RapsysAir/mail/recover.html.twig'
98 text: '@RapsysAir/mail/recover.text.twig'
99 context:
100 # Register replacement
101 register:
102 field:
103 city: false
104 country: false
105 phone: false
106 pseudonym: false
107 zipcode: false
108 route:
109 index: 'root'
110 confirm: 'confirm_url'
111 view:
112 form: 'Rapsys\AirBundle\Form\RegisterType'
113 name: '@RapsysAir/form/register.html.twig'
114 context:
115 title:
116 page: 'Register'
117 mail:
118 subject: 'Welcome %%recipient_name%% to %%site.title%%'
119 html: '@RapsysAir/mail/register.html.twig'
120 text: '@RapsysAir/mail/register.text.twig'
121 context:
122
123 # Doctrine configuration
124 doctrine:
125 # Dbal configuration
126 dbal:
127 charset: 'utf8mb4'
128 default_table_options:
129 charset: 'utf8mb4'
130 collation: 'utf8mb4_unicode_ci'
131
132 # Orm configuration
133 orm:
134 # Replace repository factory
135 repository_factory: 'Rapsys\AirBundle\Factory'
136
137 # Force resolution of UserBundle entities to AirBundle one
138 # XXX: without these lines, relations are lookup in parent namespace ignoring AirBundle extension
139 resolve_target_entities:
140 Rapsys\UserBundle\Entity\Group: 'Rapsys\AirBundle\Entity\Group'
141 Rapsys\UserBundle\Entity\Civility: 'Rapsys\AirBundle\Entity\Civility'
142 Rapsys\UserBundle\Entity\User: 'Rapsys\AirBundle\Entity\User'
143
144 mappings:
145 # Map entities
146 # XXX: Entity short syntax was removed
147 # XXX: see https://github.com/doctrine/orm/issues/8818
148 RapsysAirBundle:
149 type: 'yml'
150 is_bundle: true
151 dir: 'Resources/config/doctrine'
152 prefix: 'Rapsys\AirBundle\Entity'
153 alias: 'RapsysAirBundle'
154
155 # Security configuration
156 security:
157 # Set password hashers
158 password_hashers:
159 # Rapsys\AirBundle\Entity\User: plaintext
160 Rapsys\AirBundle\Entity\User:
161 algorithm: 'bcrypt'
162
163 # Set providers
164 providers:
165 database:
166 entity:
167 class: 'Rapsys\AirBundle\Entity\User'
168 property: 'mail'
169
170 # Set firewall
171 firewalls:
172 # Disables authentication for assets and the profiler, adapt it according to your needs
173 dev:
174 pattern: '^/(_(profiler|wdt)|css|images|js)/'
175 security: false
176
177 main:
178 # Allow anonymous access
179 #anonymous: ~
180 #lazy: true
181
182 # Activate database provider
183 provider: 'database'
184
185 # XXX: https://symfony.com/doc/current/security.html#a-configuring-how-your-users-will-authenticate
186 #http_basic: ~
187
188 # Set form login
189 # XXX: see https://symfony.com/doc/current/security/form_login_setup.html
190 # XXX: see https://symfony.com/doc/current/security/custom_authenticator.html
191 form_login:
192 # Redirect to referer if different from login route
193 use_referer: true
194 # Login path
195 login_path: 'rapsysuser_login'
196 # Check path
197 check_path: 'rapsysuser_login'
198 # Username parameter
199 username_parameter: 'login[mail]'
200 # Password parameter
201 password_parameter: 'login[password]'
202
203 # Set logout route
204 logout:
205 # Logout route
206 path: 'rapsysuser_logout'
207 # Logout default target
208 target: 'rapsysair'
209
210 # Set custom access denied handler
211 access_denied_handler: 'Rapsys\AirBundle\Handler\AccessDeniedHandler'
212
213 # Remember me
214 # XXX: see https://symfony.com/doc/current/security/remember_me.html
215 remember_me:
216 # Use APP_SECRET
217 secret: '%kernel.secret%'
218 # Always remember me
219 always_remember_me: true
220
221 # Set role hierarchy
222 role_hierarchy:
223 ROLE_GUEST: [ 'ROLE_USER' ]
224 ROLE_REGULAR: [ 'ROLE_USER', 'ROLE_GUEST' ]
225 ROLE_SENIOR: [ 'ROLE_USER', 'ROLE_GUEST', 'ROLE_REGULAR' ]
226 ROLE_ADMIN: [ 'ROLE_USER', 'ROLE_GUEST', 'ROLE_REGULAR', 'ROLE_SENIOR' ]
227
228 # Framework configuration
229 framework:
230 # Cache
231 cache:
232 # Memcache server
233 default_memcached_provider: 'memcached://localhost:11211'
234 # Cache pool
235 pools:
236 # Air cache
237 air.cache:
238 adapter: 'cache.adapter.memcached'
239 # User cache
240 user.cache:
241 adapter: 'cache.adapter.memcached'
242 default_locale: '%rapsysair.locale%'
243 disallow_search_engine_index: false
244 #error_controller: 'Rapsys\AirBundle\Controller\ErrorController::show'
245 # Append ip to mail headers
246 mailer:
247 headers:
248 X-Originating-IP: '%env(string:REMOTE_ADDR)%'
249 secret: '%env(string:APP_SECRET)%'
250 # Native session
251 session:
252 enabled: true
253 handler_id: ~
254 storage_factory_id: 'session.storage.factory.native'
255 cookie_secure: 'auto'
256 cookie_samesite: 'lax'
257 translator:
258 fallbacks: '%rapsysair.locales%'
259 validation:
260 email_validation_mode: 'html5'
261
262 # Service configuration
263 services:
264 # Register application controller
265 Rapsys\AirBundle\Controller\ApplicationController:
266 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
267 tags: [ 'controller.service_arguments' ]
268 # Register calendar controller
269 Rapsys\AirBundle\Controller\CalendarController:
270 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
271 tags: [ 'controller.service_arguments' ]
272 # Register default controller
273 Rapsys\AirBundle\Controller\DefaultController:
274 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
275 tags: [ 'controller.service_arguments' ]
276 # Register dance controller
277 Rapsys\AirBundle\Controller\DanceController:
278 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
279 tags: [ 'controller.service_arguments' ]
280 # Register location controller
281 Rapsys\AirBundle\Controller\LocationController:
282 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
283 tags: [ 'controller.service_arguments' ]
284 # Register user controller
285 Rapsys\AirBundle\Controller\UserController:
286 arguments: [ '@user.cache', '@security.authorization_checker', '@service_container', '@doctrine', '@form.factory', '@security.user_password_hasher', '@logger', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
287 tags: [ 'controller.service_arguments' ]
288 # Register session controller
289 Rapsys\AirBundle\Controller\SessionController:
290 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
291 tags: [ 'controller.service_arguments' ]
292 # Register snippet controller
293 Rapsys\AirBundle\Controller\SnippetController:
294 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
295 tags: [ 'controller.service_arguments' ]
296 # Register error controller
297 Rapsys\AirBundle\Controller\ErrorController:
298 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
299 #arguments: [ '@service_container', '@router', '@translator' ]
300 tags: [ 'controller.service_arguments' ]
301 # Register access denied handler
302 Rapsys\AirBundle\Handler\AccessDeniedHandler:
303 arguments: [ '@security.authorization_checker', '@service_container', '@rapsysuser.access_decision_manager', '@doctrine', '@rapsysair.facebook_util', '@form.factory', '@rapsyspack.image_util', '@mailer.mailer', '@doctrine.orm.default_entity_manager', '@rapsyspack.map_util', '@rapsyspack.path_package', '@router', '@security.helper', '@rapsyspack.slugger_util', '@request_stack', '@translator', '@twig' ]
304 # Register air fixtures
305 Rapsys\AirBundle\DataFixtures\AirFixtures:
306 arguments: [ '@service_container', '@security.user_password_hasher' ]
307 tags: [ 'doctrine.fixture.orm' ]
308 # Register application form
309 Rapsys\AirBundle\Form\ApplicationType:
310 arguments: [ '@doctrine', '@translator' ]
311 tags: [ 'form.type' ]
312 # Register location form
313 Rapsys\AirBundle\Form\LocationType:
314 tags: [ 'form.type' ]
315 # Register session form
316 Rapsys\AirBundle\Form\SessionType:
317 arguments: [ '@doctrine' ]
318 tags: [ 'form.type' ]
319 # Register hidden entity form type
320 Rapsys\AirBundle\Form\Extension\Type\HiddenEntityType:
321 arguments: [ '@doctrine' ]
322 tags: [ 'form.type' ]
323 # Register contact form
324 Rapsys\AirBundle\Form\ContactType:
325 arguments: [ '@rapsyspack.image_util', '@rapsyspack.slugger_util', '@translator' ]
326 tags: [ 'form.type' ]
327 # Register register form
328 Rapsys\AirBundle\Form\RegisterType:
329 arguments: [ '@doctrine.orm.entity_manager' ]
330 tags: [ 'form.type' ]
331 # Register attribute command
332 Rapsys\AirBundle\Command\AttributeCommand:
333 arguments: [ '@doctrine' ]
334 tags: [ 'console.command' ]
335 # Register calendar command
336 Rapsys\AirBundle\Command\CalendarCommand:
337 arguments: [ '@doctrine', '%kernel.default_locale%', '@router', '@rapsyspack.slugger_util', '@translator', 'airlibre', 0, '%kernel.project_dir%/var/cache' ]
338 tags: [ 'console.command' ]
339 # Register calendar2 command
340 Rapsys\AirBundle\Command\Calendar2Command:
341 arguments: [ '@doctrine', '%kernel.default_locale%', '@router', '@rapsyspack.slugger_util', '@translator' ]
342 tags: [ 'console.command' ]
343 # Register rekey command
344 Rapsys\AirBundle\Command\RekeyCommand:
345 arguments: [ '@doctrine' ]
346 tags: [ 'console.command' ]
347 # Register weather command
348 Rapsys\AirBundle\Command\WeatherCommand:
349 arguments: [ '@doctrine', '@filesystem' ]
350 tags: [ 'console.command' ]
351 # Register repository factory
352 Rapsys\AirBundle\Factory:
353 arguments: [ '@request_stack', '@router', '@rapsyspack.slugger_util', '@translator', '%kernel.default_locale%', '%rapsysair.languages%' ]
354 # Register facebook util service
355 rapsysair.facebook_util:
356 class: 'Rapsys\PackBundle\Util\FacebookUtil'
357 arguments: [ '@router', '%kernel.project_dir%/var/cache', '%rapsyspack.path%', 'facebook', '%rapsysair.path%/png/facebook.png', { irishgrover: '%rapsysair.path%/ttf/irishgrover.v10.ttf', labelleaurore: '%rapsysair.path%/ttf/labelleaurore.v10.ttf', dejavusans: '%rapsysair.path%/ttf/dejavusans.2.37.ttf', droidsans: '%rapsysair.path%/ttf/droidsans.regular.ttf' } ]
358 public: true
359 # Register security password_hasher_factory as public
360 # XXX: required for command `php bin/console doctrine:`
361 security.password_hasher_factory:
362 class: 'Symfony\Component\PasswordHasher\Hasher\PasswordHasherFactory'
363 arguments: [ { 'Rapsys\AirBundle\Entity\User': { class: 'Symfony\Component\PasswordHasher\Hasher\NativePasswordHasher', arguments: [ ~, ~, ~, '2y'] } } ]
364 public: true
365 # Register facebook event subscriber
366 Rapsys\PackBundle\Subscriber\FacebookSubscriber:
367 arguments: [ '@router', '%rapsysair.locales%' ]
368 tags: [ 'kernel.event_subscriber' ]
369 # Register dotenv:dump command
370 Symfony\Component\Dotenv\Command\DotenvDumpCommand: ~
371
372 # Twig Configuration
373 twig:
374 # Enforce debug
375 #auto_reload: ~
376 debug: '%kernel.debug%'
377 #strict_variables: '%kernel.debug%'
378
379 # Disable cache
380 # XXX: enable forced regeneration of css and js at each page load
381 cache: false
382
383 # Fix form layout for css
384 # XXX: @RapsysAir is a shortcut to vendor/rapsys/airbundle/Resources/views directory here
385 form_theme: [ '@RapsysAir/form/form_div_layout.html.twig' ]
386
387 # Set twig paths
388 paths:
389 # Required by email.image(site_logo) directive
390 # XXX: Allow twig to resolve @RapsysAir/png/logo.png in vendor/rapsys/airbundle/Resources/public/png/logo.png
391 '%kernel.project_dir%/vendor/rapsys/airbundle/Resources/public': 'RapsysAir'
392 # Override default exception controller
393 #exception_controller: Rapsys\AirBundle\Controller\ErrorController::preview