Coolwsd.xml keeps getting rewritten on updates

I have a working copy of CODE in which I have several domains that can use this with alias_groups as mode groups with several of the following

<group> 
<host allow="true" desc="hostname to allow or deny.">https://domain.ca</host> 
</group>

All those domains are working and can use it. However, every time CODE needs to be updated, this files gets overwritten. I assume coolwsd.xml is subject to overwrites for update purposes

Lucky I learned my lesson and keep a copy of this. But it is not practical. There must be a solution out there I just can’t find?

For instance, fail2ban has a jail.local file that is not subject to overwrites. Is there such a thing for this?

COOLWSD version:
23.05.1.2
git hash:
[a708901]

This problem occurs if you have virtualmin installed and are doing updates through its web interface. It selects the default behaviour when the apk manager asks what to do with the Configuration file

Configuration file '/etc/coolwsd/coolwsd.xml'
 ==> Modified (by you or by a script) since installation.
 ==> Package distributor has shipped an updated version.
   What would you like to do about it ?  Your options are:
    Y or I  : install the package maintainer's version
    N or O  : keep your currently-installed version
      D     : show the differences between the versions
      Z     : start a shell to examine the situation
 The default action is to keep your current version.
*** coolwsd.xml (Y/I/N/O/D/Z) [default=N] ? Installing new version of config file /etc/coolwsd/coolwsd.xml ...
Setting up code-brand (24.04-8) ...
Processing triggers for man-db (2.8.5-2+deb10u1) ...
Processing triggers for libc-bin (2.28-10+deb10u3) ...
Updating coolwsd systemplate
1 Like

Great @gstlouis ! Thanks for coming back to this topic and posting your solution.

(I see a lot of helpful debug discussion was going on in that linked Github topic too.)