
* Split MQTT documentation * Add more details * Move content to /docs * Enable sidebar * Move content to /docs * Enable sidebar * Move content * Update links * Remove wizard stuff * Enable sidebar * Minor changes * Move MQTT parts to /docs * update links * Update links and sync content * Fix link * Enable sidebar * Remove navigation * Remove navigation and other minor updates * Update links * Add overview page * Make title linkable * Update * Plit content * Update links * Rearrange content * New getting-started section * Add icons for docs * Update for new structure * Update for new structure * Add docs navigation * Add docs overview page * Remove ecosystem navigation * Add docs and remove other collections * Move ecosystem to docs * Remove duplicate files * Re-add ecosystem overview * Move to ecosystem * Fix permission * Update navigation * Remove collection * Move overview to right folder * Move mqtt to upper level * Move notebook to ecosystem * Remove un-used files * Add one more rectangle for iOS * Move two parts back from docs and rename Run step * Remove colon * update getting-started section * Add redirect * Update * Update navigation
3.7 KiB
layout, title, description, release_date, sidebar, comments, sharing, footer, redirect_from
layout | title | description | release_date | sidebar | comments | sharing | footer | redirect_from |
---|---|---|---|---|---|---|---|---|
page | Configuration | AppDaemon Configuration | 2016-11-27 08:00:00 -0500 | true | false | true | true | /ecosystem/appdaemon/configuration/ |
When you have appdaemon installed by either method, copy the conf/appdaemon.cfg.example
file to conf/appdaemon.cfg
, then edit the [AppDaemon]
section to reflect your environment:
[AppDaemon]
ha_url = <some_url>
ha_key = <some key>
logfile = STDOUT
errorfile = STDERR
app_dir = <Path to appdaemon dir>/conf/apps
threads = 10
latitude = <latitude>
longitude = <longitude>
elevation = <elevation
timezone = <timezone>
cert_path = <path/to/root/CA/cert>
# Apps
[hello_world]
module = hello
class = HelloWorld
ha_url
is a reference to your home assistant installation and must include the correct port number and scheme (http://
orhttps://
as appropriate)ha_key
should be set to your key if you have one, otherwise it can be removed.logfile
(optional) is the path to where you wantAppDaemon
to keep its main log. When run from the command line this is not used - log messages come out on the terminal. When running as a daemon this is where the log information will go. In the example above I created a directory specifically for AppDaemon to run from, although there is no reason you can't keep it in theappdaemon
directory of the cloned repository. Iflogfile = STDOUT
, output will be sent to stdout instead of stderr when running in the foreground, if not specified, output will be sent to STDOUT.errorfile
(optional) is the name of the logfile for errors - this will usually be errors during compilation and execution of the apps. Iferrorfile = STDERR
errors will be sent to stderr instead of a file, if not specified, output will be sent to STDERR.app_dir
(optional) is the directory the apps are placed in. If not specified, AppDaemon will look first in~/.homeassistant
then/etc/appdaemon
for a subdirectory namedapps
threads
- the number of dedicated worker threads to create for running the apps. Note, this will bear no resembelance to the number of apps you have, the threads are re-used and only active for as long as required to tun a particular callback or initialization, leave this set to 10 unless you experience thread starvationlatitude
,longitude
,elevation
,timezone
- should all be copied from your home assistant configuration filecert_path
(optional) - path to root CA cert directory - use only if you are using self signed certs.
The #Apps
section is the configuration for the Hello World program and should be left in place for initial testing but can be removed later if desired, as other Apps are added, App configuration is described in the API doc.
{% linkable_title Docker %}
For Docker Configuration you need to take a couple of extra things into consideration.
Our Docker image is designed to load your configuration and apps from a volume at /conf
so that you can manage them in your own git repository, or place them anywhere else on the system and map them using the Docker command line.
For example, if you have a local repository in /Users/foo/ha-config
containing the following files:
$ git ls-files
configuration.yaml
customize.yaml
known_devices.yaml
appdaemon.cfg
apps
apps/magic.py
You will need to modify the appdaemon.cfg
file to point to these apps in /conf/apps
:
[AppDaemon]
ha_url = <some_url>
ha_key = <some key>
logfile = STDOUT
errorfile = STDERR
app_dir = /conf/apps
threads = 10
latitude = <latitude>
longitude = <longitude>
elevation = <elevation
timezone = <timezone>
You can run Docker and point the conf volume to that directory.