Switch Server name Docker

Deployed an instance in Docker. We changed the Server name and after rebooting the container we couldn’t get into Docker. (previously the container ID was specified). How to change the Server name through the container itself? In what config is this key, line?

Hello @ICEY3Q ,

Can you provide me some information regarding the reason why it was necessary to change the hostname of the container ?

Note that normally this kind of changes are not preserved when the container is recreated (for example if the container is recreated to use an updated image).