I wanted to give a note for server operators in here that it looks like the old SIGTERM-doesn't-save bug on Linux has actually been fixed for a few builds now via Unity 2022.2 and higher.
Original ticket: https://valheimbugs.featureupvote.com/suggestions/159711/dedicated-server-does-not-save-world-on-sigterm
Upstream ticket: https://issuetracker.unity3d.com/issues/unity-server-run-time-does-not-respond-to-sigterm-and-other-linux-signals-correctly
I am sorry to those I insisted spend extra time on implementing SIGINT recently and to contradicting you @frozen zephyr when you suggested SIGTERM ought to be fine recently
Sadly, both SIGTERM and SIGINT fail to save the world on the macOS Valheim Dedicated Server currently.
