From 89e09826f772e204e5b3c84e42f1bd50b8b584f3 Mon Sep 17 00:00:00 2001 From: GenZmeY Date: Sat, 8 Aug 2020 03:47:28 +0300 Subject: [PATCH] fix: correct old kf2-srv execs --- SOURCES/main/systemd/kf2-srv-beta-update.service | 12 ++++++------ SOURCES/main/systemd/kf2-srv-update.service | 12 ++++++------ SPECS/kf2-srv.spec | 4 ++-- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/SOURCES/main/systemd/kf2-srv-beta-update.service b/SOURCES/main/systemd/kf2-srv-beta-update.service index a6c9bd4..829ffb0 100644 --- a/SOURCES/main/systemd/kf2-srv-beta-update.service +++ b/SOURCES/main/systemd/kf2-srv-beta-update.service @@ -6,20 +6,20 @@ Requires=network-online.target [Service] Type=oneshot -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta --chat '.' -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta --chat 'Server will restart after 30 minutes' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta instance chat '.' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta instance chat 'Server will restart after 30 minutes' ExecStart=/bin/sleep 15m -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta --chat 'Server will restart after 15 minutes' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta instance chat 'Server will restart after 15 minutes' ExecStart=/bin/sleep 10m -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta --chat 'Server will restart after 5 minutes' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta instance chat 'Server will restart after 5 minutes' ExecStart=/bin/sleep 5m -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta --chat 'Server shutting down...' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta instance chat 'Server shutting down...' ExecStart=/bin/sleep 5s -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta --update +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv-beta game update PrivateTmp=true PrivateDevices=true diff --git a/SOURCES/main/systemd/kf2-srv-update.service b/SOURCES/main/systemd/kf2-srv-update.service index 3a24bf5..37fb47f 100644 --- a/SOURCES/main/systemd/kf2-srv-update.service +++ b/SOURCES/main/systemd/kf2-srv-update.service @@ -6,20 +6,20 @@ Requires=network-online.target [Service] Type=oneshot -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv --chat '.' -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv --chat 'Server will restart after 30 minutes' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv instance chat '.' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv instance chat 'Server will restart after 30 minutes' ExecStart=/bin/sleep 15m -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv --chat 'Server will restart after 15 minutes' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv instance chat 'Server will restart after 15 minutes' ExecStart=/bin/sleep 10m -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv --chat 'Server will restart after 5 minutes' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv instance chat 'Server will restart after 5 minutes' ExecStart=/bin/sleep 5m -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv --chat 'Server shutting down...' +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv instance chat 'Server shutting down...' ExecStart=/bin/sleep 5s -ExecStart=:DEFINE_PREFIX:/bin/kf2-srv --update +ExecStart=:DEFINE_PREFIX:/bin/kf2-srv instance update PrivateTmp=true PrivateDevices=true diff --git a/SPECS/kf2-srv.spec b/SPECS/kf2-srv.spec index c396301..a31b92b 100644 --- a/SPECS/kf2-srv.spec +++ b/SPECS/kf2-srv.spec @@ -83,8 +83,8 @@ rm -rf $RPM_BUILD_ROOT %preun if [[ $1 -eq 0 ]] ; then # Uninstall - %{_bindir}/%{name} --stop - %{_bindir}/%{name} --disable + %{_bindir}/%{name} instance stop + %{_bindir}/%{name} instance disable rm -rf %{_prefix}/games/%{name}/* rm -rf %{_prefix}/games/%{name}-beta/* rm -rf %{_sysconfdir}/%{name}/instances/default