📝 Preliminary Checks
👀 What Happened?
A user has identified a bug similar to one recently resolved by #3380 where a setting is updated by appending a value, but repeated restarts do not check if it was already appended (internal config is expected to be deterministic at startup, not modified from prior restart).
|
sed -i -E 's|^(smtpd_milters =.*)|\1 \$rspamd_milter|g' /etc/postfix/main.cf |
This sed approach has been used a fair bit and may result in similar bugs elsewhere.
Internal state persisting across restarts is a known concern
This isn't too surprising; maintainers are well aware of DMS not playing well with restarts. We've given explicit advice in many issues to properly restart DMS via either:
docker compose down (ctrl +c alone is not equivalent) + docker compose up
docker compose up --force-recreate (no down command required).
Our docs also try raise awareness in Usage guide (perhaps should also mention in Debugging docs):
Internal configs being changed may not be deterministic with current scripts otherwise. While this approach won't help if any volume mounted configs (that aren't copied internally) were modified by DMS, but we tend to have less assumptions by scripts in those cases to avoid the problem.
👟 Reproduction Steps
No response
🐋 DMS Version
12.1 / edge
💻 Operating System and Architecture
N/A
⚙️ Container configuration files
No response
📜 Relevant log output
No response
Improvements to this form?
No response
📝 Preliminary Checks
👀 What Happened?
A user has identified a bug similar to one recently resolved by #3380 where a setting is updated by appending a value, but repeated restarts do not check if it was already appended (internal config is expected to be deterministic at startup, not modified from prior restart).
docker-mailserver/target/scripts/startup/setup.d/security/rspamd.sh
Line 141 in 8f97171
This
sedapproach has been used a fair bit and may result in similar bugs elsewhere.Internal state persisting across restarts is a known concern
This isn't too surprising; maintainers are well aware of DMS not playing well with restarts. We've given explicit advice in many issues to properly restart DMS via either:
docker compose down(ctrl +calone is not equivalent) +docker compose updocker compose up --force-recreate(nodowncommand required).Our docs also try raise awareness in Usage guide (perhaps should also mention in Debugging docs):
Internal configs being changed may not be deterministic with current scripts otherwise. While this approach won't help if any volume mounted configs (that aren't copied internally) were modified by DMS, but we tend to have less assumptions by scripts in those cases to avoid the problem.
👟 Reproduction Steps
No response
🐋 DMS Version
12.1 / edge
💻 Operating System and Architecture
N/A
⚙️ Container configuration files
No response
📜 Relevant log output
No response
Improvements to this form?
No response