Generic way to override generated configs options

Discuss

There are options in applications, that are not available n the gui but in the config file. For example I have set up a S3 storage in mastodon or enabled federation in forgejo.
The problem is, with every update, these changes to the config files get replaced with the default options from the package. Is there a generic yunohost way to conserve these changes?