README.md 1.74 KB
Newer Older
Joakim Sørensen's avatar
Joakim Sørensen committed
1
# Custom_component for [ha-dockermon](https://github.com/philhawthorne/ha-dockermon)
2
  
3
[![Version](https://img.shields.io/badge/version-2.0.2-green.svg?style=for-the-badge)](#) [![mantained](https://img.shields.io/maintenance/yes/2018.svg?style=for-the-badge)](#) [![maintainer](https://img.shields.io/badge/maintainer-Joakim%20Sørensen%20%40ludeeus-blue.svg?style=for-the-badge)](#)   
4
A custom platform which allows you to interact with [ha-dockermon.](https://github.com/philhawthorne/ha-dockermon)
5
  
6
To get started put `/custom_components/switch/hadockermon.py` here:  
7
`<config directory>/custom_components/switch/hadockermon.py`  
8
9
  
**Example configuration.yaml:**
Joakim Sørensen's avatar
Joakim Sørensen committed
10
```yaml
11
switch:
12
13
14
15
  platform: hadockermon
  host: 192.168.1.50
  port: 8126
  stats: true
16
  prefix: hadockermon
17
  exclude:
18
19
    - 'NGINX'
    - 'ha-dockermon'
Joakim Sørensen's avatar
Joakim Sørensen committed
20
```
21
**Configuration variables:**  
22
  
23
key | description  
24
:--- | :---  
25
**platform (Required)** | The platform name.  
26
**host (Required)** | The IP address of your Docker host.  
27
28
**port (Optional)** | The port that the service is exposed on.  
**stats (Optional)** | Show memory and network usage of the containers, this does _not_ work on every docker host.  
29
**prefix (Optional)** | A string that will prefix the entity name, for easy sort and grouping.  
30
**exclude (Optional)** | A list of Docker containers you want to exclude.  
31
  
32
33
34
#### Sample overview
![Sample overview](overview.png)
  
35
[Home-Assistant demo site.](https://ha-test-hadockermon.halfdecent.io/)
36
  
37
To start using this make sure you have [ha-dockermon](https://github.com/philhawthorne/ha-dockermon) running.  
38
  
39
***
40
Due to how `custom_componentes` are loaded, it is normal to see a `ModuleNotFoundError` error on first boot after adding this, to resolve it, restart Home-Assistant.