This repository was archived by the owner on Feb 6, 2022. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 154
Allow to setup connection settings as URI #101
Comments
But how will that work for more complex transporters? :) |
@sstok Not like this :) I didn't intended to replace the existing setup, but to allow to simplify it (as long as it makes sense and works). Do you have an example of a transport, that may not work? Actually ... As far as I can see |
fabpot
added a commit
that referenced
this issue
Jan 14, 2016
This PR was merged into the 2.3-dev branch. Discussion ---------- 5AF0 Allow to setup transports via URL | Q | A | ------------- | --- | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | #101 | License | MIT | Doc PR | - For example as YML ```yml swiftmailer: default_mailer: smtp_mailer mailers: smtp_mailer: url: smtp://username:password@example.com:12345?encryption=tls&auth_mode=login ``` This is primary useful for SMTP-transports. There is no benefit, for "sendmail"-, or "mail"-transports. The intention is, that one only needs to set up one config option/parameter to define a working transport. For example see [`parameters.yml` of `symfony/symfony-standard`](https://github.com/symfony/symfony-standard/blob/2.8/app/config/parameters.yml.dist#L13-L16) ```yml mailer_transport: smtp mailer_host: 127.0.0.1 mailer_user: ~ mailer_password: ~ ``` For different stages one usually must set at least "user" and "password" and often "host" too for every stage. With this patch it would look like ``` mailer_url: 'smtp://127.0.0.1' ``` Commits ------- 49219dc Allow to setup transports via URL
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
It would be nice, if one can configure one connection with a single string (URI, ...) instead of multiple separate configuration keys
The text was updated successfully, but these errors were encountered: