Description
Since https://github.com/spf13/viper/releases/tag/v1.6.0, viper support INI file config.
What do you think of migrating to this library to store config in various format (INI, Toml, Env variable, etcd, consul, ...) ?
I think this would remove a lot of code logic from gitea and help readability of the config code.
This would also ease the compatibility with container environnement via env variable or distributed config manager support (etcd, consul)
This would also ease the compatibility with FHS linux distribution by looking at multiple standard path for configuration.
Another point, this would allow support for live reloading of some configuration (and maybe could be used by UI) but this would not be the primary goal.
Somewhat related issues/change that could be replaced: #7287 #6923