Changes to dolibarr files are being deleted or replaced

hi, i am using dolibarr 21.0.1. My issue is with making changes to dolibarr files. I see that whenever i make changes to certain files, they get deleted and go back to the original file. for example i tried changing the agenda file inside the third parties module: /htdocs/societe/agenda.php, and after a day or so, the change disappeared and the file got back to the original.

anybody knows why this is happening and how to go around this? i would love some help

are you using a container based setup?

yes. dolibarr is installed on a docker container that runs on a VM.

that is probably why.

I use these tools to run my development dolibarr

You probably have to modify my scripts a little bit.

What you can do is that you fork the dolibarr github repository in the branches (versions) you want. Then you clone that repo to your own local disk into the branches you want. Make your changes in that repo and commit it to your own Dolibarr forked repo in your github account.

What my devtainer scripts do is that they mount a dolibarr repo ontop of the containers dolibarr directory.

When you want to make changes, you do a backup inside dolibarr, then you load a new mariadb from that file (the scripts show how). At the same time you create a new branch where you can make your changes in the code, you then develop your own dolibarr and safely test it with a copy of production data.

However, since you have modified (core) files in Dolbiarr, you will have to port them for each new version of dolibarr.

But luckily the container based setup my script will make it easy for you to do an upgrade with a copy of your production data.

@carguin has made some comments to me about this setup that I have not yet had the time to look into :frowning:

1 Like

Thank you very very much for your help :folded_hands:. i will look into it.