-
Notifications
You must be signed in to change notification settings - Fork 288
Description
Hi,
I've been trying to use papercut in a development environment that runs in an ipv6-only kubernetes cluster, and had a few problems. It seems like the configuration values for SMTP server IP and Port are ignored?
My goals are to listen on address ::
(IPv6Any) and port 8025
. However, whatever I try, the container logs always say:
[timestamp] Starting Smtp Server on 0.0.0.0:25...
I'm unable to affect the above, neither address nor port, no matter what I do. I was able to change the HTTP addr/port easily by adding a Urls
field to appsettings.json
, so this seems to only be a problem for SMTP.
I've tried:
appsettings.json
:
{
"SmtpServer": {
"Port": 8025
}
}
appsettings.Production.json
:
{
"SmtpServer": {
"Port": 8025
}
}
Papercut.SMTP.Service.Settings.json
:
{
"Port": "8025"
}
Papercut.Service.Settings.json
:
{
"Port": "8025"
}
environment vars:
PORT=8025
SMTP_PORT=8025
The only way I could find to get it working is to run a reverse proxy process to forward incoming ipv6 connections to ipv4, and run the process as root within its container (because binding to ports < 1024 requires special credentials).
So, I want to ask: what's the right way to configure the SMTP service's ip/port when running the papercut-smtp docker image? And would it be possible to provide an example of that?
Thanks!