I want to install a soil server in Docker, but it turns out that port 25 is busy in OMV. How to release it or switch to another port. OMV still cannot receive incoming mail.

How to free port 25 for mail server?
-
- resolved
- OMV 6.x
- AHTOH
-
-
in docker is really easy.
in yaml file change ports:
25:25
by your desired port eg: 2525:25
left side external port
right side port used by app inside the docker.
PD: Then if you need, you can change in your router forwaded ports: from 25 external to 2525 internal (IPofYourNAS)
-
-
-
Try 4pda:
-
Not working.
-
I would either run the mail server in a VM or use macvlan in docker so that the container gets its own IP address.
-
-
-
But I really need this port.
And you can use that port if you use a macvlan network. I have a mysql system at work that has 8 containers listening on 3306. They each get their own IP address. So, no port conflicts.
-
Fine. Prohibit OMV listening to port 25 will not work?
-
-
Fine. Prohibit OMV listening to port 25 will not work?
Why do you not want to use macvlan? OMV depends on postfix and OMV controls the postfix config. Trying to hack OMV to not use port 25 is a LOT more effort than just using macvlan.
-
Ok. I'll try
-
Here is an example of how to use and create a macvlan network in the compose plugin - https://github.com/sarunas-zil…master/docker-compose.yml
-
-
Yes. I did it with his help. A very nice plugin!
-
Why do you not want to use macvlan? OMV depends on postfix and OMV controls the postfix config. Trying to hack OMV to not use port 25 is a LOT more effort than just using macvlan.
I made it very simple:
nano /srv/salt/omv/deploy/postfix/30master.sls
Codecustomize_postfix_master: file.replace: - name: "/etc/postfix/master.cf" - pattern: "smtp inet n - n - - smtpd" - repl: "26 inet n - n - - smtpd"
After reboot, postfix in OMV listens to port 26. Port 25 is now free for dockerized mailcow.
-
I made it very simple:
That will be overwritten on upgrades. Why not use macvlan or bridge?
-
-
Even the docker-compose that mailcow recommends using a bridge which would negate the need to change OMV files https://github.com/mailcow/mai…r/docker-compose.yml#L617
-
That will be overwritten on upgrades. Why not use macvlan?
It's been working for me for six months now. The file 30master.sls is specially created to always prescribe port 26 in postfix when updating.
-
It's been working for me for six months now.
I didn't say it wouldn't work. Just think it is over-complicating things and even going against the mailcow recommendation.
The file 30master.sls is specially created to always prescribe port 26 in postfix when updating.
Ah, I thought you were just editing an existing file.
-
-
Just think it is over-complicating things
What's so hard about creating a new file of three lines and doing nothing else?
-
I created macvlan, vm w/ slackware, isntalled postfix/dovecot and my 25 works fine on same system as OMV.
Participate now!
Don’t have an account yet? Register yourself now and be a part of our community!