diff options
author | Renken <renken@shione.net> | 2024-02-20 00:08:52 +0100 |
---|---|---|
committer | Renken <renken@shione.net> | 2024-05-12 16:49:44 +0200 |
commit | 67886f809d57c06b8a232cb461801f11e57f68a3 (patch) | |
tree | d575b00acef24f99887be1fc99b7236401825e91 | |
parent | 84a5868bc4710aff0fa9b449501e162dace47a30 (diff) | |
download | shione-67886f809d57c06b8a232cb461801f11e57f68a3.tar.gz shione-67886f809d57c06b8a232cb461801f11e57f68a3.zip |
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.
-rwxr-xr-x | deploy/shione/srb2kart/deploy.sh | 16 | ||||
-rw-r--r-- | deploy/shione/srb2kart/srb2kart.service | 7 | ||||
-rw-r--r-- | deploy/shione/srb2kart/srb2kart.socket | 3 |
3 files changed, 22 insertions, 4 deletions
diff --git a/deploy/shione/srb2kart/deploy.sh b/deploy/shione/srb2kart/deploy.sh index 0209dd6..6ed1d20 100755 --- a/deploy/shione/srb2kart/deploy.sh +++ b/deploy/shione/srb2kart/deploy.sh @@ -4,5 +4,17 @@ set -eu ./generate_dkartconfig.sh -rsync -a --progress srb2kart.service srb2kart@shione:/home/srb2kart/.config/systemd/user -rsync -a --delete --progress dkartconfig.cfg mods srb2kart@shione:/home/srb2kart/.srb2kart +rsync \ + -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 diff --git a/deploy/shione/srb2kart/srb2kart.service b/deploy/shione/srb2kart/srb2kart.service index d9806ba..807b820 100644 --- a/deploy/shione/srb2kart/srb2kart.service +++ b/deploy/shione/srb2kart/srb2kart.service @@ -5,9 +5,12 @@ StartLimitIntervalSec=0 [Service] PermissionsStartOnly=false +Sockets=srb2kart.socket +StandardInput=socket +StandardError=journal Environment=LC_ALL=C -ExecStart=/usr/bin/byobu new-session -ds srb2kart srb2kartd -Type=forking +ExecStart=/home/srb2kart/.local/bin/srb2kart -dedicated +Type=simple RemainAfterExit=false Restart=always RestartSec=1s diff --git a/deploy/shione/srb2kart/srb2kart.socket b/deploy/shione/srb2kart/srb2kart.socket new file mode 100644 index 0000000..a3e355e --- /dev/null +++ b/deploy/shione/srb2kart/srb2kart.socket @@ -0,0 +1,3 @@ +[Socket] +ListenFIFO=%t/srb2kart.stdin +Service=srb2kart.service |