Change server URL (domain name)

Assume I created a seafile server named and everything works.
I now need to change (without doing a sever migration) the domain name and url to a new one.
What files should I change in server side?

You have to change the preferences in the ccnet-db database (You can do that with the WebUI in the WebUi preferences) and the domain name in your nginx/apache config.