2021-07-06 19:40:41 +02:00

1.9 KiB
Raw Blame History

Configuration check

{% if page.installation == "os" or page.installation == "supervised" %}

ha core check

{% elsif page.installation == "container" %}

If your container name is something other than homeassistant, change that part in the examples below.

Run the full check:

docker exec homeassistant python -m homeassistant --script check_config --config /config

Listing all loaded files:

docker exec homeassistant python -m homeassistant --script check_config --files

Viewing a components configuration (light in this example):

docker exec homeassistant python -m homeassistant --script check_config --info light

Or all components configuration

docker exec homeassistant python -m homeassistant --script check_config --info all

You can get help from the command line using:

docker exec homeassistant python -m homeassistant --script check_config --help

{% elsif page.installation == "core" %}

  1. Switch to the user that is running Home Assistant

    sudo -u homeassistant -H -s
    
  2. Activate the virtual environment that Home Assistant is running in

    source /srv/homeassistant/bin/activate
    
  3. Run the configuration check

    Run the full check:

    hass --script check_config
    

    Listing all loaded files:

    hass --script check_config --files
    

    Viewing a components configuration (light in this example):

    hass --script check_config --info light
    

    Or all components configuration

    hass --script check_config --info all
    

    You can get help from the command line using:

    hass --script check_config --help
    
  4. When that is complete restart the service for it to use the new files.

{% endif %}