logging does not work in all configuration cases
Hi, i figured out that there seems to be some issue with the setting of the logging of BFFH:
the following settings will make bffh correctly talkative (trace level):
export BFFH_LOG=trace; /opt/fabinfra/bffh/target/release/bffhd --config /opt/fabinfra/bffh-data/config/cfg.dhall
BFFH_LOG=trace /opt/fabinfra/bffh/target/release/bffhd --config /opt/fabinfra/bffh-data/config/cfg.dhall
i put this into my systemd file:
[Unit]
Description=FabAccess BFFH Service
After=network.target
[Service]
Type=simple
User=bffh
Group=root
ExecStartPre=/opt/fabinfra/bffh/target/release/bffhd --check --config /opt/fabinfra/bffh-data/config/cfg.dhall
Environment="BFFH_LOG=warn"
ExecStart=/opt/fabinfra/bffh/target/release/bffhd --verbose --config /opt/fabinfra/bffh-data/config/cfg.dhall --log-format Full
Restart=on-failure
RestartSec=30
ExecStopPost=/usr/bin/bash /opt/fabinfra/fabaccess-bffh-state.sh $EXIT_CODE
[Install]
WantedBy=multi-user.target
while the following settings do not apply to print proper output:
/opt/fabinfra/bffh/target/release/bffhd --config /opt/fabinfra/bffh-data/config/cfg.dhall --log-level trace
or setting it in config.dhall, like the docs say:
via BFFH_LOG="trace",
See https://fab-access.readthedocs.io/en/v0.3/configuration/log_config.html and the output of bffhd:
diflouroborane 0.4.2
USAGE:
bffhd [OPTIONS]
OPTIONS:
-c, --config <config> Path to the config file to use
--check Check config for validity
--dump Dump all internal databases
--dump-users <FILE> Dump the users db to the given file as TOML
--force force ops that may clobber
-h, --help Print help information
--load <load> Load values into the internal databases
--log-format <log format> Use an alternative log formatter. Available: Full, Compact,
Pretty [possible values: Full, Compact, Pretty]
--log-level <log level> Set the desired log levels.
--print-default Print a default config to stdout instead of running
--quiet Decrease logging verbosity
--tls-key-log [<PATH>...] log TLS keys into PATH. If no path is specified the value of
the envvar SSLKEYLOGFILE is used.
-v, --verbose Increase logging verbosity
-V, --version Print version information