[Add] debugging to systemd nix service

This commit is contained in:
Alois 2026-05-17 20:06:08 +02:00
commit b7f6ccf8a7

View file

@ -179,11 +179,9 @@
ExecStart = if cfg.useTmux then ExecStart = if cfg.useTmux then
pkgs.writeShellScript "iota-start" '' pkgs.writeShellScript "iota-start" ''
${pkgs.tmux}/bin/tmux -S ${cfg.dataDir}/tmux.sock new-session -d -s iota ' ${pkgs.tmux}/bin/tmux -S ${cfg.dataDir}/tmux.sock new-session -d -s iota '
echo "debug: starting iota..."
${cfg.package}/bin/iota 2>&1 | ${pkgs.coreutils}/bin/tee ${cfg.dataDir}/iota-output.log ${cfg.package}/bin/iota 2>&1 | ${pkgs.coreutils}/bin/tee ${cfg.dataDir}/iota-output.log
EXIT_CODE=$? EXIT_CODE=$?
echo ""
echo "============================================"
echo "Iota exited with code: $EXIT_CODE"
echo "Output saved to: ${cfg.dataDir}/iota-output.log" echo "Output saved to: ${cfg.dataDir}/iota-output.log"
echo "Press ENTER to close this session..." echo "Press ENTER to close this session..."
read -r read -r