Running Stalwart behind Caddy #488
Replies: 6 comments 17 replies
-
The reason I created this setup is that in this way you can have both mail and http running at the root-domain. www is redirected to the root and webmin is running behind mail.domain.tld. Now you can start a small VM for every venture or cool idea that you think of. |
Beta Was this translation helpful? Give feedback.
-
Thank you! I finally got it running with this config |
Beta Was this translation helpful? Give feedback.
-
Could you also tell to which ports your router/firewall points to? 443 for caddy and the rest for stalwart? Or all to caddy? I am still a little confused. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Is there any good way to get caddy to foward the real ip to stalwart to log? |
Beta Was this translation helpful? Give feedback.
-
Does Stalwart automatically reload the certificate if the underlying file changes? The docs suggest it doesn't and that it needs an extra command to reload them, which is missing from this solution. |
Beta Was this translation helpful? Give feedback.
-
I have managed to get Stalwart to run behind Caddy. There are only a couple of things you have to do.
This is my Caddyfile, yours might differ of course:
After succesfully starting Caddy you can copy the certificate files to your Stalwart dir:
Put the following in root's crontab,it needs to be root because of ownership of different files...
add the following to your config.toml:
Now you can safely (re)start Stalwart and finish configuration in Webmin.
Beta Was this translation helpful? Give feedback.
All reactions