diff --git a/docs/installation/advanced/metrics.md b/docs/installation/advanced/metrics.md index 78c1b9191..004e48da6 100644 --- a/docs/installation/advanced/metrics.md +++ b/docs/installation/advanced/metrics.md @@ -9,6 +9,7 @@ Currently, the following SeaTable components expose metrics in a [Prometheus](ht - api-gateway - dtable-db +- caddy In addition, **Gunicorn** and **NGINX** can be configured to expose metrics in a different format. Exporters can be used to transform these into a Prometheus-compatible format. @@ -334,6 +335,44 @@ curl -sS http://127.0.0.1:9113/metrics ``` +### Caddy + +[Caddy](https://caddyserver.com/) natively supports exposing metrics in a Prometheus-compatible format. Since SeaTable uses [caddy-docker-proxy](https://github.com/lucaslorentz/caddy-docker-proxy), metrics can be enabled by adding Docker labels to the Caddy service. + +Create a `caddy-metrics.yml` file in your `/opt/seatable-compose` directory: + +```yaml +services: + caddy: + labels: + caddy_0.metrics: + caddy_0.metrics.per_host: + caddy_1: ":2020" + caddy_1.metrics: /metrics + ports: + - 127.0.0.1:2020:2020 + networks: + - o11y-net + +networks: + o11y-net: + name: o11y-net +``` + +These labels configure Caddy to collect per-host metrics and expose them on a dedicated, read-only endpoint on port 2020 (separate from the Caddy Admin API on port 2019). + +Add `caddy-metrics.yml` to the `COMPOSE_FILE` variable in your `.env` file and restart the containers: + +```bash +docker compose up -d +``` + +You can test the metrics endpoint by running the following command on the host: + +```bash +curl -sS http://127.0.0.1:2020/metrics +``` + ## Scraping There are many ways to ingest the metrics into Prometheus. @@ -407,6 +446,17 @@ prometheus.scrape "seatable_metrics" { forward_to = [prometheus.remote_write.default.receiver] scrape_interval = "15s" } + +// Caddy metrics do not use basic authentication and +// therefore require a separate scrape configuration. +prometheus.scrape "caddy_metrics" { + targets = [ + {"__address__" = "caddy:2020", "instance" = "caddy"}, + ] + + forward_to = [prometheus.remote_write.default.receiver] + scrape_interval = "15s" +} ``` ## Grafana Dashboard diff --git a/docs/installation/components/python-pipeline.md b/docs/installation/components/python-pipeline.md index 39ce2053a..49cf3057a 100644 --- a/docs/installation/components/python-pipeline.md +++ b/docs/installation/components/python-pipeline.md @@ -52,6 +52,7 @@ The generated shared secret needs to be added to your `.env` file. Copy and past ```bash echo -e "\n# python-pipeline" >> /opt/seatable-compose/.env +echo "ENABLE_PYTHON_SCRIPT=true" >> /opt/seatable-compose/.env echo "PYTHON_SCHEDULER_AUTH_TOKEN=${pw}" >> /opt/seatable-compose/.env ``` diff --git a/docs/upgrade/extra-upgrade-notice.md b/docs/upgrade/extra-upgrade-notice.md index 8772441df..5a75c46a6 100644 --- a/docs/upgrade/extra-upgrade-notice.md +++ b/docs/upgrade/extra-upgrade-notice.md @@ -1,5 +1,13 @@ # Extra upgrade notice +## 6.1 + +Several Docker image tags have been updated to newer versions. These changes are applied automatically when you pull the latest images. Remember to also update your [plugins](../configuration/plugins.md). + +??? warning "Python Pipeline requires explicit activation" + + Starting with version 6.1, the default value for `ENABLE_PYTHON_SCRIPT` has been changed from `true` to `false`. If you use the Python Pipeline, you must ensure that `ENABLE_PYTHON_SCRIPT=true` is set in your `/opt/seatable-compose/.env` file. Without this setting, Python script execution will be disabled after the upgrade. + ## 6.0 **No special steps are required for this upgrade.**