diff --git a/roles/terraria/templates/terraria@.service b/roles/terraria/templates/terraria@.service index 0f912e0..9e116aa 100644 --- a/roles/terraria/templates/terraria@.service +++ b/roles/terraria/templates/terraria@.service @@ -21,10 +21,10 @@ ProtectKernelModules=true # Implies MountAPIVFS=yes ProtectControlGroups=true -ExecStart=/bin/sh -c '/usr/bin/screen -DmS ter-%i ./TerrariaServer.bin.x86_64 -config config' +ExecStart=/bin/sh -c '/usr/bin/screen -DmS %i ./TerrariaServer.bin.x86_64 -config config' -ExecStop=/usr/bin/screen -p 0 -S ter-%i -X eval 'stuff "say Server is going down: Service was stopped"\\015' -ExecStop=/usr/bin/screen -p 0 -S ter-%i -X eval 'stuff "exit"\\015' +ExecStop=/usr/bin/screen -p 0 -S %i -X eval 'stuff "say Server is going down: Service was stopped"\\015' +ExecStop=/usr/bin/screen -p 0 -S %i -X eval 'stuff "exit"\\015' ExecStop=/bin/sleep 5 Restart=always