Merge branch 'dev'

This commit is contained in:
shamoon 2024-11-24 08:16:04 -08:00
commit 1656f02418
62 changed files with 1307 additions and 176 deletions

View file

@ -100,6 +100,8 @@ If you are using multiple instances of homepage, an `instance` annotation can be
If you have a single service that needs to be shown on multiple specific instances of homepage (but not on all of them), the service can be annotated by multiple `instance.name` annotations, where `name` can be the names of your specific multiple homepage instances. For example, a service that is annotated with `gethomepage.dev/instance.public: ""` and `gethomepage.dev/instance.internal: ""` will be shown on `public` and `internal` homepage instances.
Use the `gethomepage.dev/pod-selector` selector to specify the pod used for the health check. For example, a service that is annotated with `gethomepage.dev/pod-selector: app.kubernetes.io/name=deployment` would link to a pod with the label `app.kubernetes.io/name: deployment`.
### Traefik IngressRoute support
Homepage can also read ingresses defined using the Traefik IngressRoute custom resource definition. Due to the complex nature of Traefik routing rules, it is required for the `gethomepage.dev/href` annotation to be set:

View file

@ -71,7 +71,7 @@ Homepage provides a set of common translations that you can use in your widgets.
| `common.ms` | `1,000 ms` | Format a number in milliseconds. |
| `common.date` | `2024-01-01` | Format a date. |
| `common.relativeDate` | `1 day ago` | Format a relative date. |
| `common.uptime` | `1 day, 1 hour` | Format an uptime. |
| `common.duration` | `1 day, 1 hour` | Format an duration. |
### Text

View file

@ -5,7 +5,11 @@ description: Unifi Controller Information Widget Configuration
_(Find the Unifi Controller service widget [here](../services/unifi-controller.md))_
You can display general connectivity status from your Unifi (Network) Controller. When authenticating you will want to use a local account that has at least read privileges.
You can display general connectivity status from your Unifi (Network) Controller.
!!!
When authenticating you will want to use a local account that has at least read privileges.
An optional 'site' parameter can be supplied, if it is not the widget will use the default site for the controller.

View file

@ -0,0 +1,33 @@
---
title: ArgoCD
description: ArgoCD Widget Configuration
---
Learn more about [ArgoCD](https://argo-cd.readthedocs.io/en/stable/).
Allowed fields (limited to a max of 4): `["apps", "synced", "outOfSync", "healthy", "progressing", "degraded", "suspended", "missing"]`
```yaml
widget:
type: argocd
url: http://argocd.host.or.ip:port
key: argocdapikey
```
You can generate an API key either by creating a bearer token for an existing account, see [Authorization](https://argo-cd.readthedocs.io/en/latest/developer-guide/api-docs/#authorization) (not recommended) or create a new local user account with limited privileges and generate an authentication token for this account. To do this the steps are:
- [Create a new local user](https://argo-cd.readthedocs.io/en/stable/operator-manual/user-management/#create-new-user) and give it the `apiKey` capability
- Setup [RBAC configuration](https://argo-cd.readthedocs.io/en/stable/operator-manual/rbac/#rbac-configuration) for your the user and give it readonly access to your ArgoCD resources, e.g. by giving it the `role:readonly` role.
- In your ArgoCD project under _Settings / Accounts_ open the newly created account and in the _Tokens_ section click on _Generate New_ to generate an access token, optionally specifying an expiry date.
If you installed ArgoCD via the official Helm chart, the account creation and rbac config can be achived by overriding these helm values:
```yaml
configs:
cm:
accounts.readonly: apiKey
rbac:
policy.csv: "g, readonly, role:readonly"
```
This creates a new account called `readonly` and attaches the `role:readonly` role to it.

View file

@ -0,0 +1,22 @@
---
title: Beszel
description: Beszel Widget Configuration
---
Learn more about [Beszel](https://github.com/henrygd/beszel)
The widget has two modes, a single system with detailed info if `systemId` is provided, or an overview of all systems if `systemId` is not provided.
The `systemID` in the `id` field on the collections page of Beszel.
Allowed fields for 'overview' mode: `["systems", "up"]`
Allowed fields for a single system: `["name", "status", "updated", "cpu", "memory", "disk", "network"]`
```yaml
widget:
type: beszel
url: http://beszel.host.or.ip
username: username # email
password: password
systemId: systemId # optional
```

View file

@ -0,0 +1,20 @@
---
title: Gitlab
description: Gitlab Widget Configuration
---
Learn more about [Gitlab](https://gitlab.com).
API requires a personal access token with either `read_api` or `api` permission. See the [gitlab documentation](https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html#create-a-personal-access-token) for details on generating one.
Your Gitlab user ID can be found on [your profile page](https://support.circleci.com/hc/en-us/articles/20761157174043-How-to-find-your-GitLab-User-ID).
Allowed fields: `["events", "issues", "merges", "projects"]`.
```yaml
widget:
type: gitlab
url: http://gitlab.host.or.ip:port
key: personal-access-token
user_id: 123456
```

View file

@ -0,0 +1,19 @@
---
title: Headscale
description: Headscale Widget Configuration
---
Learn more about [Headscale](https://headscale.net/).
You will need to generate an API access token from the [command line](https://headscale.net/ref/remote-cli/#create-an-api-key) using `headscale apikeys create` command.
To find your node ID, you can use `headscale nodes list` command.
Allowed fields: `["name", "address", "last_seen", "status"]`.
```yaml
widget:
type: headscale
nodeId: nodeid
key: headscaleapiaccesstoken
```

View file

@ -8,12 +8,14 @@ search:
You can also find a list of all available service widgets in the sidebar navigation.
- [Adguard Home](adguard-home.md)
- [ArgoCD](argocd.md)
- [Atsumeru](atsumeru.md)
- [Audiobookshelf](audiobookshelf.md)
- [Authentik](authentik.md)
- [Autobrr](autobrr.md)
- [Azure DevOps](azuredevops.md)
- [Bazarr](bazarr.md)
- [Beszel](beszel.md)
- [Caddy](caddy.md)
- [Calendar](calendar.md)
- [Calibre-Web](calibre-web.md)
@ -39,11 +41,13 @@ You can also find a list of all available service widgets in the sidebar navigat
- [Gatus](gatus.md)
- [Ghostfolio](ghostfolio.md)
- [Gitea](gitea.md)
- [Gitlab](gitlab.md)
- [Glances](glances.md)
- [Gluetun](gluetun.md)
- [Gotify](gotify.md)
- [Grafana](grafana.md)
- [HDHomeRun](hdhomerun.md)
- [Headscale](headscale.md)
- [Healthchecks](healthchecks.md)
- [Home Assistant](homeassistant.md)
- [HomeBox](homebox.md)
@ -96,6 +100,7 @@ You can also find a list of all available service widgets in the sidebar navigat
- [Plex](plex.md)
- [Portainer](portainer.md)
- [Prometheus](prometheus.md)
- [Prometheus Metric](prometheusmetric.md)
- [Prowlarr](prowlarr.md)
- [Proxmox](proxmox.md)
- [Proxmox Backup Server](proxmoxbackupserver.md)

View file

@ -0,0 +1,67 @@
---
title: Prometheus Metric
description: Prometheus Metric Widget Configuration
---
Learn more about [Querying Prometheus](https://prometheus.io/docs/prometheus/latest/querying/basics/).
This widget can show metrics for your service defined by PromQL queries which are requested from a running Prometheus instance.
Quries can be defined in the `metrics` array of the widget along with a label to be used to present the metric value. You can optionally specify a global `refreshInterval` in milliseconds and/or define the `refreshInterval` per metric. Inside the optional `format` object of a metric various formatting styles and transformations can be applied (see below).
```yaml
widget:
type: prometheusmetric
url: https://prometheus.host.or.ip
refreshInterval: 10000 # optional - in milliseconds, defaults to 10s
metrics:
- label: Metric 1
query: alertmanager_alerts{state="active"}
- label: Metric 2
query: apiserver_storage_size_bytes{node="mynode"}
format:
type: bytes
- label: Metric 3
query: avg(prometheus_notifications_latency_seconds)
format:
type: number
suffix: s
options:
maximumFractionDigits: 4
- label: Metric 4
query: time()
refreshInterval: 1000 # will override global refreshInterval
format:
type: date
scale: 1000
options:
timeStyle: medium
```
## Formatting
Supported values for `format.type` are `text`, `number`, `percent`, `bytes`, `bits`, `bbytes`, `bbits`, `byterate`, `bibyterate`, `bitrate`, `bibitrate`, `date`, `duration`, `relativeDate`, and `text` which is the default.
The `dateStyle` and `timeStyle` options of the `date` format are passed directly to [Intl.DateTimeFormat](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/DateTimeFormat/DateTimeFormat) and the `style` and `numeric` options of `relativeDate` are passed to [Intl.RelativeTimeFormat](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/RelativeTimeFormat/RelativeTimeFormat). For the `number` format, options of [Intl.NumberFormat](https://developer.mozilla.org/de/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat) can be used, e.g. `maximumFractionDigits` or `minimumFractionDigits`.
### Data Transformation
You can manipulate your metric value with the following tools: `scale`, `prefix` and `suffix`, for example:
```yaml
- query: my_custom_metric{}
label: Metric 1
format:
type: number
scale: 1000 # multiplies value by a number or fraction string e.g. 1/16
- query: my_custom_metric{}
label: Metric 2
format:
type: number
prefix: "$" # prefixes value with given string
- query: my_custom_metric{}
label: Metric 3
format:
type: number
suffix: "€" # suffixes value with given string
```

View file

@ -0,0 +1,15 @@
---
title: Spoolman
description: Spoolman Widget Configuration
---
Learn more about [Spoolman](https://github.com/Donkie/Spoolman).
4 spools are displayed by default. If more than 4 spools are configured in spoolman you can use the spoolIds configuration option to control which are displayed.
```yaml
widget:
type: spoolman
url: http://spoolman.host.or.ip
spoolIds: [1, 2, 3, 4] # optional
```

View file

@ -0,0 +1,20 @@
---
title: Suwayomi
description: Suwayomi Widget Configuration
---
Learn more about [Suwayomi](https://github.com/Suwayomi/Suwayomi-Server).
Allowed fields: ["download", "nondownload", "read", "unread", "downloadedread", "downloadedunread", "nondownloadedread", "nondownloadedunread"]
The widget defaults to the first four above. If more than four fields are provided, only the first 4 are displayed.
Category IDs can be obtained from the url when navigating to it, `?tab={categoryID}`.
```yaml
widget:
type: suwayomi
url: http://suwayomi.host.or.ip
username: username #optional
password: password #optional
category: 0 #optional, defaults to all categories
```

View file

@ -7,7 +7,11 @@ Learn more about [Unifi Controller](https://ui.com/).
_(Find the Unifi Controller information widget [here](../info/unifi_controller.md))_
You can display general connectivity status from your Unifi (Network) Controller. When authenticating you will want to use a local account that has at least read privileges.
You can display general connectivity status from your Unifi (Network) Controller.
!!!
When authenticating you will want to use a local account that has at least read privileges.
An optional 'site' parameter can be supplied, if it is not the widget will use the default site for the controller.