config: ensure SASL socket file is not inside a volume mount#3125
config: ensure SASL socket file is not inside a volume mount#3125DavyLandman wants to merge 3 commits intodocker-mailserver:masterfrom DavyLandman:sasl-socket-move
Conversation
See #3110 for more details
We have a rather good documentation on how we run tests if that is something you are wondering about. If it is about the change itself, I'm not 100% certain either. I guess running it and seeing whether it produces errors is a good way to start :) I will add some comments, but the changes as-is look quite good. |
FYI: running the test fails with: so I ran
yeah, I was thinking, how to test in a single test. (without having setup lots of temp records) |
Co-authored-by: Georg Lauterbach <[email protected]>
We don't have any known way to reproduce it. Best we can do is check logs for the same permission failures, but if we can't reproduce the conditions to fail reliably, I'd rather not. There's this PR and the linked issue which has plenty of details behind the change / issue, if we need to revisit this after release. |
Are you on a Linux host? What version is your Docker Engine? |
U was running it on an unused vps somewhere: |
Excuse me, but it is explicitly written in the docs: "You will first need to build the container image via |
🤦🏼 my bad |
|
Could you try logging in via SSH with X-Forwarding? The errror "Cannot autolaunch D-Bus without X11 $DISPLAY" suggests |
|
Ahh, there we go: https://anto.online/guides/cannot-autolaunch-d-bus-without-x11-display/. Maybe |
| -o smtpd_sasl_auth_enable=yes | ||
| -o smtpd_sasl_type=dovecot | ||
| -o smtpd_sasl_path=private/auth | ||
| -o smtpd_sasl_path=/dev/shm/sasl-auth.sock |
There was a problem hiding this comment.
Unrelated to the actual issue, but @polarathene any idea why we overwrite the default here with the same value? Does not make sense to me really..
I'd do this:
| -o smtpd_sasl_path=private/auth | |
| -o smtpd_sasl_path=/dev/shm/sasl-auth.sock |
There was a problem hiding this comment.
Probably just how it was originally contributed / configured (or from multiple contributions) that we got a default path in main.cf and another in master.cf 🤷♂️
The prior relative path was to be scoped to the chroot jail at /var/spool/postfix, but I guess the answer is just misconfiguration, or copy/paste from guides / snippets online without trying to understand it much 😅
Should be safe to drop I think, but we can do that in a future PR if preferred. I am short on time to double check.
|
After updating docker the error persists. No idea why I need credentials to pull stuff (as in, not that chatty from this vps). |
| -o smtpd_sasl_auth_enable=yes | ||
| -o smtpd_sasl_type=dovecot | ||
| -o smtpd_sasl_path=private/auth | ||
| -o smtpd_sasl_path=/dev/shm/sasl-auth.sock |
There was a problem hiding this comment.
Here as well:
| -o smtpd_sasl_path=private/auth | |
| -o smtpd_sasl_path=/dev/shm/sasl-auth.sock |
|
Docker seems to be trying to invoke a credentials helper which requires a graphical frontent, which of course is not enabled. Can you try logging out of all registries with Docker? AFAIK you do not need any credentials for building DMS. |
|
in the end, some googling pointed out outdated credential helpers. did the trick. such fun. it's now building. curious if I can also get this |
|
I actuall think this is a sporadic failure.. seems unrelated to me. Tests have been restarted. UPDATE: Seems not to be sporadic.. weird. I am currently unable to investigate too, but maybe I can find some time today or tomorrow. Nevermind, found the issue: https://github.com/docker-mailserver/docker-mailserver/blob/master/test/config/dovecot-lmtp/user-patches.sh. The EDIT2: I am not yet sure how to go about this. @polarathene any idea? EDIT3: Something like EDIT4: We could delete the whole sed -i '/service lmtp {/,+13d' /etc/dovecot/conf.d/10-master.conf
cat >>/etc/dovecot/conf.d/10-master.conf << EOF
service lmtp {
inet_listener lmtp {
address = 0.0.0.0
port = 24
}
}
EOF |
|
The failure happening in this PR is because of
Yeah I guess that works. I think that section could be moved to a separate file and use the include syntax to have Dovecot handle it. Then the test would just replace that include line or config file. |
|
Yeah; using an include and changing the path if required is probably the best idea! |
|
hey @georglauterbach it seems you have a better idea of what to change, so will you propose a patch? |
I can provide a patch and we can then rebase this PR. EDIT: I have two pending PRs in the pipeline that I am currently waiting for to be merged; I will apply the patch afterwards: |
|
I'm also fine with closing this PR in favor of a new PR that you make that merges these changes? I mean, I'm happy I could help diagnose this issue a bit, I don't need to have my name on the commits ;) |
|
No worries, we'll take care of it if you like 👍 |
|
Alright; let's leave this open for now, I will close it when merging the PR that supersedes this PR. |
|
Superseeded by #3131 |
See #3110 for more details
Description
The sasl socket was on a path that would end up getting volume mounted (
/var/mail-state) in some setups, this could cause issues. The socket is not actually state, so it doesn't need to end up there.Fixes #3110
Type of change
Checklist:
docs/)note, I've marked it as Draft because:
/dev/shminstead.