Open git-bruh opened 2 years ago
Currently all runit services just spam the tty on boot, and logs aren't stored anywhere. I use the following script to enable logging on my server:
#!/usr/bin/env sh LOG_BASE="${1:-/var/log/sv}" # /etc/sv/$sv_name/log sv_name="$(basename "$(realpath "$PWD/..")")" logdir="$LOG_BASE/$sv_name" mkdir -p "$logdir" exec svlogd -tt "$logdir"
Enabled per-package with another script:
#!/usr/bin/env sh set -eu SV="$1" SVBASE="/etc/sv" RUNBASE="/run/runit" LOGDIR="$SVBASE/$SV/log" [ ! "$SV" ] && exit 1 [ -d "$SVBASE/$SV" ] || exit 1 mkdir -p "$LOGDIR" ln -sf "$SVBASE/logger" "$LOGDIR/run" ln -sf "$RUNBASE/supervise.$SV-logger" "$LOGDIR/supervise"
Should we include something like this in the default busybox package or is it better suited for community?
ping @illiliti @ioraff
I think something like this should be included in the busybox package
It's good idea and I agree with ioraff. However, we need to sort out realpath usage first.
https://codeberg.org/kiss-community/repo/issues/82
Currently all runit services just spam the tty on boot, and logs aren't stored anywhere. I use the following script to enable logging on my server:
Enabled per-package with another script:
Should we include something like this in the default busybox package or is it better suited for community?
ping @illiliti @ioraff