@@ -151,6 +151,15 @@ Configuration
151
151
152
152
* :ref: `name <reference-lock-resources-name >`
153
153
154
+ * `mailer `_
155
+
156
+ * :ref: `dsn <mailer-dsn >`
157
+ * `transports `_
158
+ * `envelope `_
159
+
160
+ * `sender `_
161
+ * `recipients `_
162
+
154
163
* `php_errors `_
155
164
156
165
* `log `_
@@ -159,7 +168,7 @@ Configuration
159
168
* `profiler `_
160
169
161
170
* `collect `_
162
- * `dsn `_
171
+ * :ref: `dsn < profiler-dsn >`
163
172
* :ref: `enabled <reference-profiler-enabled >`
164
173
* `only_exceptions `_
165
174
* `only_master_requests `_
@@ -1075,6 +1084,8 @@ only_master_requests
1075
1084
When this is set to ``true ``, the profiler will only be enabled on the master
1076
1085
requests (and not on the subrequests).
1077
1086
1087
+ .. _profiler-dsn :
1088
+
1078
1089
dsn
1079
1090
...
1080
1091
@@ -2932,6 +2943,88 @@ Name of the lock you want to create.
2932
2943
decorates : lock.invoice.store
2933
2944
arguments : ['@lock.invoice.retry_till_save.store.inner', 100, 50]
2934
2945
2946
+ mailer
2947
+ ~~~~~~
2948
+
2949
+ .. _mailer-dsn :
2950
+
2951
+ dsn
2952
+ ...
2953
+
2954
+ **type **: ``string ``
2955
+
2956
+ The DSN used by the mailer. When several DSN may be used, use `transports ` (see below) instead.
2957
+
2958
+ transports
2959
+ ..........
2960
+
2961
+ **type **: ``array ``
2962
+
2963
+ A :ref: `list of DSN <multiple-email-transports >` that can be used by the mailer. A transport name is the key and the dsn is the value.
2964
+
2965
+ envelope
2966
+ ........
2967
+
2968
+ sender
2969
+ """"""
2970
+
2971
+ **type **: ``string ``
2972
+
2973
+ Sender used by the `Mailer `. Keep in mind that this setting override a sender set in the code.
2974
+
2975
+ recipients
2976
+ """"""""""
2977
+
2978
+ **type **: ``array ``
2979
+
2980
+ Recipients used by the `Mailer `. Keep in mind that this setting override recipients set in the code.
2981
+
2982
+ .. configuration-block ::
2983
+
2984
+ .. code-block :: yaml
2985
+ # config/packages/mailer.yaml
2986
+ framework :
2987
+ mailer :
2988
+ dsn : ' smtp://localhost:25'
2989
+ envelope :
2990
+
2991
+
2992
+ .. code-block :: xml
2993
+ <!-- config/packages/mailer.xml -->
2994
+ <?xml version =" 1.0" encoding =" UTF-8" ?>
2995
+ <container xmlns =" http://symfony.com/schema/dic/services"
2996
+ xmlns : xsi =" http://www.w3.org/2001/XMLSchema-instance"
2997
+ xmlns : framework =" http://symfony.com/schema/dic/symfony"
2998
+ xsi : schemaLocation =" http://symfony.com/schema/dic/services
2999
+ https://symfony.com/schema/dic/services/services-1.0.xsd
3000
+ http://symfony.com/schema/dic/symfony https://symfony.com/schema/dic/symfony/symfony-1.0.xsd" >
3001
+ <framework : config >
3002
+ <framework : mailer dsn =" smtp://localhost:25" >
3003
+ <framework : envelope >
3004
+ <framework : recipients >[email protected] </framework : recipients >
3005
+ <framework : recipients >[email protected] </framework : recipients >
3006
+ </framework : envelope >
3007
+ </framework : mailer >
3008
+ </framework : config >
3009
+ </container >
3010
+
3011
+ .. code-block :: php
3012
+ // config/packages/mailer.php
3013
+ namespace Symfony\Component\DependencyInjection\Loader\Configurator;
3014
+ return static function (ContainerConfigurator $containerConfigurator): void {
3015
+ $containerConfigurator->extension('framework', [
3016
+ 'mailer' => [
3017
+ 'dsn' => 'smtp://localhost:25',
3018
+ 'envelope' => [
3019
+ 'recipients' => [
3020
+
3021
+
3022
+ ]
3023
+ ]
3024
+ ]
3025
+ ]);
3026
+ };
3027
+
2935
3028
workflows
2936
3029
~~~~~~~~~
2937
3030
0 commit comments