Skip to content

Commit 1d89cbc

Browse files
author
Miguel Medinilla
committed
Simplify decision-spoa environment toggles
1 parent 0e5508b commit 1d89cbc

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ env GOTOOLCHAIN=local go build -trimpath -o build/decision-configcheck ./cmd/dec
5151

5252
Append `--check-config` to validate the policy directory and exit without starting the service.
5353

54-
The Debian/RPM packages install a `decision-spoa.service` systemd unit that uses `/etc/default/decision-spoa` to pass CLI options. The stock configuration listens on `127.0.0.1:9908`, exposes metrics on `127.0.0.1:9907`, and enables best-effort GeoIP downloads. Optional high-cardinality metrics (`--metrics-host-label`, `--metrics-geoip`) remain disabled unless explicitly added to `DECISION_SPOA_OPTS`.
54+
The Debian/RPM packages install a `decision-spoa.service` systemd unit that uses `/etc/default/decision-spoa` to pass CLI options. The stock configuration listens on `127.0.0.1:9908`, exposes metrics on `127.0.0.1:9907`, and enables best-effort GeoIP downloads. Optional high-cardinality metrics remain disabled unless you set `DECISION_METRICS_HOST_LABEL`/`DECISION_METRICS_GEOIP` in that file.
5555

5656
### Flags and environment variables
5757

@@ -105,8 +105,12 @@ DECISION_SPOA_OPTS="\
105105
--asn-db /var/lib/decision/GeoLite2-ASN.mmdb \
106106
--city-url https://hub-data.crowdsec.net/mmdb_update/GeoLite2-City.mmdb \
107107
--asn-url https://hub-data.crowdsec.net/mmdb_update/GeoLite2-ASN.mmdb \
108-
--best-effort \
109-
--metrics-host-label"
108+
--best-effort"
109+
110+
# Optional toggles; uncomment as needed.
111+
# DECISION_DEBUG=1
112+
# DECISION_METRICS_HOST_LABEL=1
113+
# DECISION_METRICS_GEOIP=1
110114

111115
# /etc/default/decision-geoip-db-updates
112116
DECISION_GEOIP_DB_UPDATES_OPTS="\

packaging/default/decision-spoa

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ DECISION_SPOA_OPTS="\
1111
--asn-url https://hub-data.crowdsec.net/mmdb_update/GeoLite2-ASN.mmdb \
1212
--best-effort"
1313

14-
# Add optional high-cardinality toggles when needed:
15-
# DECISION_SPOA_OPTS="$DECISION_SPOA_OPTS --metrics-host-label"
16-
# DECISION_SPOA_OPTS="$DECISION_SPOA_OPTS --metrics-geoip"
14+
# Optional toggles. Uncomment the lines you need.
15+
# DECISION_DEBUG=1
16+
# DECISION_METRICS_HOST_LABEL=1
17+
# DECISION_METRICS_GEOIP=1

0 commit comments

Comments
 (0)