srb2kart: read standard input from socket

Drop dependency on byobu, currently the socket solution does not work
but it shouldn't be too hard to fix it.
This commit is contained in:
Renken 2024-02-20 00:08:52 +01:00
parent 84a5868bc4
commit 67886f809d
Signed by: renken
GPG key ID: 1F2BB159B645E575
3 changed files with 22 additions and 4 deletions

View file

@ -4,5 +4,17 @@ set -eu
./generate_dkartconfig.sh ./generate_dkartconfig.sh
rsync -a --progress srb2kart.service srb2kart@shione:/home/srb2kart/.config/systemd/user rsync \
rsync -a --delete --progress dkartconfig.cfg mods srb2kart@shione:/home/srb2kart/.srb2kart -a \
--progress \
srb2kart.socket \
srb2kart.service \
srb2kart@shione:/home/srb2kart/.config/systemd/user
rsync \
-a \
--delete \
--progress \
dkartconfig.cfg \
mods \
srb2kart@shione:/home/srb2kart/.srb2kart

View file

@ -5,9 +5,12 @@ StartLimitIntervalSec=0
[Service] [Service]
PermissionsStartOnly=false PermissionsStartOnly=false
Sockets=srb2kart.socket
StandardInput=socket
StandardError=journal
Environment=LC_ALL=C Environment=LC_ALL=C
ExecStart=/usr/bin/byobu new-session -ds srb2kart srb2kartd ExecStart=/home/srb2kart/.local/bin/srb2kart -dedicated
Type=forking Type=simple
RemainAfterExit=false RemainAfterExit=false
Restart=always Restart=always
RestartSec=1s RestartSec=1s

View file

@ -0,0 +1,3 @@
[Socket]
ListenFIFO=%t/srb2kart.stdin
Service=srb2kart.service