Using Secrets.yaml - martikainen87/Home-Automation GitHub Wiki
Securing your configuration of all the information that might be sensitive to show others, this will make it safe to upload/share your configuration with others.
Open your samba share and create a new file called secrets.yaml
Bild 1
In this file we will add "links" that our main configuration can call for and get the data behind the links
For example, I want to hide the password for my Home Assistant.
in the secrets.yaml file i will add this and save the file
#HTTP webpage
api_password: Mattias
Bild 2
In the configuration.yaml add this, make sure that you remove any pre-defined texts regarding "http:", if there are 2 rows with the component "http:" the configuration will fail.
http:
api_password: !secret api_password
Now we should have the files looking similar to this
bild 2
Home Assistant will now look in the configuration.yaml file and see that there is a component called http: (read more about HTTP) It sees that there is an entry with !secret , in the next step it will look in the secrets.yaml file for a record called api_password and pass the result of that to the HTTP component, which will add a password to our site which must be entered when browsing the site.