Click here to visit repository github page.
docker pull nhea/mailservice:latest
Either MAILQUEUE_SMTPSETTINGS or MAILQUEUE_SMTPSETTINGS_FILE must be provided.
docker run --rm -it --restart unless-stopped -t nhea/mailservice:latest\
-e MAILQUEUE_CONNECTION='sqlconnectionstring'\
-e MAILQUEUE_SMTPSETTINGS='[{"From": "[email protected]", "Host": "smtp.gmail.com", "UserName": "[email protected]", "Password": "mailpassword", "Port": 587, "EnableSsl": true, "IsDefault": true, "DefaultToRecipients":"[email protected]", "DefaultSubject":"Default Subject", "Sender":"Sender Name", "AutoGeneratePlainText":false, "DisableHistoryLogging":false }]'
Smtp settings is an array and you can add more than one configuration.
services:
nhea.mailservice:
image: nhea/mailservice
restart: unless-stopped
environment:
- ASPNETCORE_ENVIRONMENT=Development
- ASPNETCORE_URLS=https://+:443;http://+:80
- 'MAILQUEUE_CONNECTION=sqlconnection'
- 'MAILQUEUE_SMTPSETTINGS=[{"From": "[email protected]", "Host": "smtp.gmail.com", "UserName": "[email protected]", "Password": "mailpassword", "Port": 587, "EnableSsl": true, "IsDefault": true, "DefaultToRecipients":"[email protected]", "DefaultSubject":"Default Subject", "Sender":"Sender Name", "AutoGeneratePlainText":false, "DisableHistoryLogging":false }]'
- MAILQUEUE_IGNORE_SSL_VALIDATION=true
By default nhea mail service sends mails via .Net Core SmtpClient. At the moment you can also use MailKit as SmtpClient too. In order to use MailKit just set 'SmtpLibrary' setting on the mail settings individually you would like to.
- 'MAILQUEUE_SMTPSETTINGS=[{"From": "[email protected]", "SmtpLibrary": "mailkit", "Host": "smtp.gmail.com", "UserName": "[email protected]", "Password": "mailpassword", "Port": 587, "EnableSsl": true, "IsDefault": true, "DefaultToRecipients":"[email protected]", "DefaultSubject":"Default Subject", "Sender":"Sender Name", "AutoGeneratePlainText":false, "DisableHistoryLogging":false }]'
Content type
Image
Digest
sha256:435773310…
Size
84.6 MB
Last updated
about 4 years ago
docker pull nhea/mailservice