Really just starting out with HA, i have been playing with seeing what all gets picked up using auto discovery and what not.
Coming from openhab, I MUCH prefer to have everything in files/db I can edit. So I like the idea of doing yaml files vs everything through the UI. So my question is, how are others that do everything in yaml how do you handle the entities? or is that done in the home-assistant_v2.db regardless?
The home-assistant_v2.db isn’t for storing or handling entities. That whrre the state history is stored.
The configuration info is stored in the files located in the hidden .storage directory.
Otherwise I’m not sure what you are asking.
HA pretty much decides for you which entities/config is done thru the ui or yaml. There are some integrations that allow both but they are getting fewer on every release.
But I agree with you about liking the control I have not using the ui and prefer yaml for most things. Alas, that’s not under our control.
This is helpful. I haven’t gone poking through the .storage directory.
Was more just curious like how a restore would go. if i had all my automations and configs setup, but if the entity id’s get regenerated if i had to restore to a new install, just curious how that would look.
If you restore from a snapshot then everything should come back exactly as it was before.
If you just restore from a manual backup and as long as you also backed up all of the hidden directories (including the .storage directory) then it should be the same as well.
soo the key thing i need to make sure i do. keep regular backups of the config directory ESPECIALLY the hidden directories.
I am guessing the stuff in the hidden directories is not really something that should be handled in the ci/cd process since that stuff is more “system” created vs config/scripts. So just my manual configs would go in my bitbucket or github.
Planning on keeping my configs and stuff in something like github or gitlab ect and having a process that I have to check in my changes before they are pushed to my HA instance. That way I have version control and checks before pushing.