packer/debian/13-trixie/scripts/crowdsec-configuration.sh

8 lines
336 B
Bash

#!/usr/bin/env bash
set -euf -o pipefail
export DEBIAN_FRONTEND=noninteractive
# Enable write-ahead-logging (wal -- allowing more concurrency in SQLite that will improve performances in most scenarios.)
sed -i -E '/^db_config:/,/^[^[:space:]]/{s/^([[:space:]]*)type:[[:space:]]*sqlite$/&\
\1use_wal: true/}' /etc/crowdsec/config.yaml