-
Notifications
You must be signed in to change notification settings - Fork 30
How to run TFS OTServ compiled for Windows
You may have to install wine if it's not installed yet. Due to the amount of space used by wine (1.1 GB), we do not pre-install it on the OTS Hosting Service.
sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt -y install wine32-development wine-development
This will allow you to run both 32-bit and 64-bit .exe files. Note that sometimes wineconsole
yields better results than using wine
directly.
otsmanager@176-31-89-137:~/ots$ wineconsole YurOTS.exe
If everything works as expected and after a minute you see a console, you may proceed to change configuration for service unit.
You need to edit /etc/systemd/system/tfs.service
and set up working directory and binary path.
otsmanager@176-31-89-137:~$ sudo mcedit /etc/systemd/system/tfs.service
Add or change the following three lines if your .exe is /home/otsmanager/ots/YurOTS.exe
Type=simple
ExecStart=/usr/bin/wine YurOTS.exe WorkingDirectory=/home/otsmanager/ots
Save the file (F2) and exit mcedit (F10).
Now you need to reload systemd configuration:
otsmanager@176-31-89-137:~$ sudo systemctl daemon-reload
And start "tfs" (the name "tfs" here refers to the filename in tfs.service):
otsmanager@176-31-89-137:~$ sudo systemctl start tfs
Check "tfs" log:
otsmanager@176-31-89-137:~$ journalctl -u tfs -f
Powered by Spigu.net Team | Get OTS Hosting Service with support | Visit our Otland Thread