]> git.immae.eu Git - github/bastienwirtz/homer.git/blob - docs/customservices.md
Update customservices.md
[github/bastienwirtz/homer.git] / docs / customservices.md
1 # Custom Services
2
3 Some service can use a specific a component that provides some extra features by adding a `type` key to the service yaml
4 configuration and, where applicable, an apikey. Note that config.yml is exposed at /assets/config.yml via HTTP and any
5 apikey included in the configuration file is exposed to anyone who can access the homer instance. Only include an apikey
6 if your homer instance is secured behind some form of authentication or access restriction.
7
8 Available services are in `src/components/`. Here is an overview of all custom services that are available
9 within Homer:
10
11 - [Custom Services](#custom-services)
12 - [Common options](#common-options)
13 - [PiHole](#pihole)
14 - [OpenWeatherMap](#openweathermap)
15 - [Medusa](#medusa)
16 - [Lidarr, Prowlarr, Sonarr and Radarr](#lidarr-prowlarr-sonarr-and-radarr)
17 - [PaperlessNG](#paperlessng)
18 - [Ping](#ping)
19 - [Prometheus](#prometheus)
20 - [AdGuard Home](#adguard-home)
21 - [Portainer](#portainer)
22 - [Emby / Jellyfin](#emby--jellyfin)
23 - [Uptime Kuma](#uptime-kuma)
24 - [Tautulli](#tautulli)
25 - [Mealie](#mealie)
26 - [Healthchecks](#healthchecks)
27 - [Proxmox](#proxmox)
28 - [rTorrent](#rtorrent)
29 - [qBittorrent](#qbittorrent)
30 - [CopyToClipboard](#copy-to-clipboard)
31 - [Speedtest Tracker](#SpeedtestTracker)
32 - [What's Up Docker](#whats-up-docker)
33
34 If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page.
35
36 ## Common options
37
38 ```yaml
39 - name: "My Service"
40 logo: "assets/tools/sample.png"
41 url: "http://my-service-link"
42 endpoint: "http://my-service-endpoint" # Optional: alternative base URL used to fetch service data is necessary.
43 useCredentials: false # Optional: Override global proxy.useCredentials configuration.
44 type: "<type>"
45 ```
46
47 ## PiHole
48
49 Using the PiHole service you can display info about your local PiHole instance right on your Homer dashboard.
50
51 The following configuration is available for the PiHole service.
52
53 ```yaml
54 - name: "Pi-hole"
55 logo: "assets/tools/sample.png"
56 # subtitle: "Network-wide Ad Blocking" # optional, if no subtitle is defined, PiHole statistics will be shown
57 url: "http://192.168.0.151/admin"
58 type: "PiHole"
59 ```
60
61 ## OpenWeatherMap
62
63 Using the OpenWeatherMap service you can display weather information about a given location.
64 The following configuration is available for the OpenWeatherMap service:
65
66 ```yaml
67 - name: "Weather"
68 location: "Amsterdam" # your location.
69 locationId: "2759794" # Optional: Specify OpenWeatherMap city ID for better accuracy
70 apikey: "<---insert-api-key-here--->" # insert your own API key here. Request one from https://openweathermap.org/api.
71 units: "metric" # units to display temperature. Can be one of: metric, imperial, kelvin. Defaults to kelvin.
72 background: "square" # choose which type of background you want behind the image. Can be one of: square, circle, none. Defaults to none.
73 type: "OpenWeather"
74 ```
75
76 **Remarks:**
77 If for some reason your city can't be found by entering the name in the `location` property, you could also try to configure the OWM city ID in the `locationId` property. To retrieve your specific City ID, go to the [OWM website](https://openweathermap.org), search for your city and retrieve the ID from the URL (for example, the City ID of Amsterdam is 2759794).
78
79 ## Medusa
80
81 This service displays News (grey), Warning (orange) or Error (red) notifications bubbles from the Medusa application.
82 Two lines are needed in the config.yml :
83
84 ```yaml
85 type: "Medusa"
86 apikey: "01234deb70424befb1f4ef6a23456789"
87 ```
88
89 The url must be the root url of Medusa application.
90 The Medusa API key can be found in General configuration > Interface. It is needed to access Medusa API.
91
92 ## Lidarr, Prowlarr, Sonarr and Radarr
93
94 This service displays Activity (blue), Warning (orange) or Error (red) notifications bubbles from the Lidarr, Radarr or Sonarr application.
95 Two lines are needed in the config.yml :
96
97 ```yaml
98 type: "Lidarr", "Prowlarr", "Radarr" or "Sonarr"
99 apikey: "01234deb70424befb1f4ef6a23456789"
100 ```
101
102 The url must be the root url of Lidarr, Prowlarr, Radarr or Sonarr application.
103 The Lidarr, Prowlarr, Radarr or Sonarr API key can be found in Settings > General. It is needed to access the API.
104 If you are using an older version of Radarr or Sonarr which don't support the new V3 api endpoints, add the following line to your service config "legacyApi: true", example:
105
106 ```yaml
107 - name: "Radarr"
108 type: "Radarr"
109 url: "http://localhost:7878/"
110 apikey: "MY-SUPER-SECRET-API-KEY"
111 target: "_blank"
112 legacyApi: true
113 ```
114
115 ## PaperlessNG
116
117 This service displays total number of documents stored. Two lines are required:
118
119 ```yaml
120 type: "PaperlessNG"
121 apikey: "0123456789abcdef123456789abcdef"
122 ```
123
124 API key can be generated in Settings > Administration > Auth Tokens
125
126 ## Ping
127
128 For Ping you need to set the type to Ping and provide a url. By default the HEAD method is used but it can be configured to use GET using the optional `method` property.
129
130 ```yaml
131 - name: "Awesome app"
132 type: Ping
133 logo: "assets/tools/sample.png"
134 subtitle: "Bookmark example"
135 tag: "app"
136 url: "https://www.reddit.com/r/selfhosted/"
137 method: "head"
138 ```
139
140 ## Prometheus
141
142 For Prometheus you need to set the type to Prometheus and provide a url.
143
144 ```yaml
145 - name: "Prometheus"
146 type: Prometheus
147 logo: "assets/tools/sample.png"
148 url: "http://192.168.0.151/"
149 # subtitle: "Monitor data server"
150 ```
151
152 ## AdGuard Home
153 For AdGuard Home you need to set the type to AdGuard, if you have somes issues as 403 responses on requests you need to provide authentification in headers for locations needed as below.
154
155 ```yaml
156 - name: "Adguard"
157 logo: "assets/tools/adguardhome.png"
158 url: "https://adguard.exemple.com"
159 target: "_blank"
160 type: "AdGuardHome"
161 ```
162
163 ## Portainer
164
165 This service displays info about the total number of containers managed by your Portainer instance.
166 In order to use it, you must be using Portainer version 1.11 or later. Generate an access token from the UI and pass
167 it to the apikey field.
168 By default, every connected environments will be checked. To select specific ones,add an "environments" entry which can be a simple string or an array containing all the selected environments name.
169
170 See https://docs.portainer.io/v/ce-2.11/user/account-settings#access-tokens
171
172 ```yaml
173 - name: "Portainer"
174 logo: "assets/tools/sample.png"
175 url: "http://192.168.0.151/"
176 type: "Portainer"
177 apikey: "MY-SUPER-SECRET-API-KEY"
178 # environments:
179 # - "raspberry"
180 # - "local"
181 ```
182
183 ## Emby / Jellyfin
184
185 You need to set the type to Emby, provide an api key and choose which stats to show if the subtitle is disabled.
186
187 ```yaml
188 - name: "Emby"
189 logo: "assets/tools/sample.png"
190 url: "http://192.168.0.151/"
191 type: "Emby"
192 apikey: "MY-SUPER-SECRET-API-KEY"
193 libraryType: "music" #Choose which stats to show. Can be one of: music, series or movies.
194 ```
195
196 ## Uptime Kuma
197
198 Using the Uptime Kuma service you can display info about your instance uptime right on your Homer dashboard.
199
200 The following configuration is available for the UptimeKuma service. Needs v1.13.1 or later because of the change in APIs due to [multiple status pages support](https://github.com/louislam/uptime-kuma/releases/tag/1.13.1).
201
202 ```yaml
203 - name: "Uptime Kuma"
204 logo: "assets/tools/sample.png"
205 # subtitle: "A fancy self-hosted monitoring tool" # optional, if no subtitle is defined, Uptime Kuma incidents, if any, will be shown
206 url: "http://192.168.0.151:3001"
207 slug: "myCustomDashboard" # Defaults to "default" if not provided.
208 type: "UptimeKuma"
209 ```
210
211 ## Tautulli
212
213 The Tautulli service can allow you to show the number of currently active
214 streams on you Plex instance. An API key is required, and can be obtained from
215 the "Web Interface" section of settings on the Tautulli web UI.
216
217 ```yaml
218 - name: "Tautulli"
219 logo: "assets/tools/sample.png"
220 url: "http://192.168.0.151:8181"
221 type: "Tautulli"
222 apikey: "MY-SUPER-SECRET-API-KEY"
223 ```
224
225 Because the service type and link don't necessarily have to match, you could
226 even make the service type Tautulli on your Plex card and provide a separate
227 endpoint pointing to Tautulli!
228
229 ```yaml
230 - name: "Plex"
231 logo: "assets/tools/sample.png"
232 url: "http://192.168.0.151:32400/web" # Plex
233 endpoint: "http://192.168.0.151:8181" # Tautulli
234 type: "Tautulli"
235 apikey: "MY-SUPER-SECRET-API-KEY"
236 ```
237
238 ## Mealie
239
240 First off make sure to remove an existing `subtitle` as it will take precedence if set.
241 Setting `type: "Mealie"` will then show the number of recipes Mealie is keeping organized or the planned meal for today if one is planned. You will have to set an API key in the field `apikey` which can be created in your Mealie installation.
242
243 ## Healthchecks
244
245 This service displays information about the configured status checks from the Healthchecks application.
246 Two lines are needed in the config.yml :
247
248 ```yaml
249 type: "Healthchecks"
250 apikey: "01234deb70424befb1f4ef6a23456789"
251 ```
252
253 The url must be the root url of the Healthchecks application.
254 The Healthchecks API key can be found in Settings > API Access > API key (read-only). The key is needed to access Healthchecks API.
255
256 ## rTorrent
257
258 This service displays the global upload and download rates, as well as the number of torrents
259 listed in rTorrent. The service communicates with the rTorrent XML-RPC interface which needs
260 to be accessible from the browser. Please consult
261 [the instructions](https://github.com/rakshasa/rtorrent-doc/blob/master/RPC-Setup-XMLRPC.md)
262 for setting up rTorrent and make sure the correct CORS-settings are applied. Examples for various
263 servers can be found at https://enable-cors.org/server.html.
264
265 ```yaml
266 - name: "rTorrent"
267 logo: "assets/tools/sample.png"
268 url: "http://192.168.0.151" # Your rTorrent web UI, f.e. ruTorrent or Flood.
269 xmlrpc: "http://192.168.0.151:8081" # Reverse proxy for rTorrent's XML-RPC.
270 type: "Rtorrent"
271 rateInterval: 5000 # Interval for updating the download and upload rates.
272 torrentInterval: 60000 # Interval for updating the torrent count.
273 username: "username" # Username for logging into rTorrent (if applicable).
274 password: "password" # Password for logging into rTorrent (if applicable).
275 ```
276
277
278 ## Proxmox
279
280 This service displays status information of a Proxmox node (VMs running and disk, memory and cpu used). It uses the proxmox API and [API Tokens](https://pve.proxmox.com/pve-docs/pveum-plain.html) for authorization so you need to generate one to set in the yaml config. You can set it up in Proxmox under Permissions > API Tokens. You also need to know the realm the user of the API Token is assigned to (by default pam).
281
282 The API Token (or the user asigned to that token if not separated permissions is checked) are this:
283
284 | Path | Permission | Comments |
285 |--------------------|------------|-------------------------------------------------------------------|
286 | /nodes/<your-node> | Sys.Audit | |
287 | /vms/<id-vm> | VM.Audit | You need to have this permission on any VM you want to be counted |
288
289 It is highly recommended that you create and API Token with only these permissions on a read-only mode.
290
291 If you get errors, they will be shown on browser's dev console. Main issues tend to be CORS related as Proxmox does not include CORS headers and you have to deploy it behind a reverse proxy and make the proxy add this headers.
292
293 Configuration example:
294
295 ```yaml
296 - name: "Proxmox - Node"
297 logo: "https://www.google.com/url?sa=i&url=https%3A%2F%2Fgithub.com%2FandOTP%2FandOTP%2Fissues%2F337&psig=AOvVaw2YKVuEUIBeTUikr7kAjm8D&ust=1665323538747000&source=images&cd=vfe&ved=0CAkQjRxqFwoTCPCTruLj0PoCFQAAAAAdAAAAABAN"
298 type: "Proxmox"
299 url: "https://your.proxmox.server"
300 node: "your-node-name"
301 warning_value: 50
302 danger_value: 80
303 api_token: "PVEAPIToken=root@pam!your-api-token-name=your-api-token-key"
304 # values below this line are optional (default value are false/empty):
305 hide_decimals: true # removes decimals from stats values.
306 hide: ["vms", "vms_total", "lxcs", "lxcs_total", "disk", "mem", "cpu"] # hides values included in the array
307 small_font_on_small_screens: true # uses small font on small screens (like mobile)
308 small_font_on_desktop: true # uses small font on desktops (just in case you're showing much info)
309 ```
310
311 ## qBittorrent
312
313 This service displays the global upload and download rates, as well as the number of torrents
314 listed. The service communicates with the qBittorrent API interface which needs
315 to be accessible from the browser. Please consult
316 [the instructions](https://github.com/qbittorrent/qBittorrent/pull/12579)
317 for setting up qBittorrent and make sure the correct CORS-settings are applied. Examples for various
318 servers can be found at [enable-cors.org](https://enable-cors.org/server.html).
319
320 ```yaml
321 - name: "qBittorrent"
322 logo: "assets/tools/sample.png"
323 url: "http://192.168.1.2:8080" # Your rTorrent web UI, f.e. ruTorrent or Flood.
324 type: "qBittorrent"
325 rateInterval: 2000 # Interval for updating the download and upload rates.
326 torrentInterval: 5000 # Interval for updating the torrent count.
327 target: "_blank" # optional html a tag target attribute
328 ```
329
330 ## Copy to Clipboard
331
332 This service displays the same information of a generic one, but shows an icon button on the indicator place (right side) you can click to get the content of the `clipboard` field copied to your clipboard.
333
334 You can still provide an `url` that would be open when clicked anywhere but on the icon button.
335
336 Configuration example:
337
338 ```yaml
339 - name: "Copy me!"
340 logo: "assets/tools/sample.png"
341 subtitle: "Subtitle text goes here"
342 url: "#"
343 type: "CopyToClipboard"
344 clipboard: "this text will be copied to your clipboard"
345 ```
346
347 ## SpeedtestTracker
348
349 For the SpeedtestTracker service you just need to define a entry with type `SpeedtestTracker`.
350
351 ## What's up Docker
352
353 What's up Docker allow to display info about the number of container running and the number for which an update is available on your Homer dashboard.
354
355 The following configuration is available for the WUD service.
356
357 ```yaml
358 - name: "What's Up Docker"
359 logo: "assets/tools/sample.png"
360 subtitle: "Docker image update notifier"
361 url: "http://192.168.1.12:3001"
362 type: "WUD"
363 ```