Docker-deployed HomeAssistant is migrated to another computer

I want to migrate the Home Assistant that I’m using on my personal Ubuntu with Docker deployment to my server host, and retain my development progress. How should I do this? Thank you.

Move the files. Rebuild container. Fix file permissions if needed

When rebuild a container, Home Assistant won’t be a fresh installation, right? That way, it won’t continue from the progress I had on my original host’s Home Assistant. Could you explain that in more detail? Thank you very much.

If you create container it will be fresh install. This is good first step if you are not confident with docker because it allows you to verify the correct file permissions for the system and verify container should start and no system problem prevents its function

In docker to must mount folders. Thats the -v /local/config.yaml:/docker/config.yaml part. To restore a previously running docker instance you must only map the file accordingly or move them into the mapped folder.

Files have user:group permissions. This is usually root:root by default and the docker container itself runs as root. Some users, like me, create a system user:group for each docker container and start the container under that user. This in theory would limit the containers access on the system in case of bug/hack. Also in the process of moving files on the system or copying files to a new system it is possible that you may change the files user:group. This goes back to the beginning where i suggest verifying the file permissions. This is not big deal. If permissions are wrong the container just won’t start or will simply not use the files as it cannot see them.

Long story short

Start new container on new system
Verify working
Stop container
Move files
Start container
If not start ok, check file permission and verify all files were moved.

HA has hidden “.storage” folder in config folder. You must ensure this gets copied over

Thank you, I understand.