First off, I'd like to thank any and all sources I've used over the years to gather all this information. I cannot name them individually, however, if you feel special enough that you think you require a listing, send me a PM and I'll put you in my list of special people.
So, first off, you'd need a server with ubuntu x64 minimal (this tutorial should work an all versions between 12.04 and 20.04 without any modification). Any other linux installation might also work (debian is closesly related to ubuntu, so the steps listed here will probably work on a debian install as well) (CentOS is not that closely related so most steps will require changing). Aquiring such a server is a thing you have to figure out for yourself. You can buy one of the many VPS's (virtual private servers) or run linux locally (on your own server/inside a VM/on your main pc) and go from there.
Step 1: Securing your server
The first steps you should always take when running any internet-facing server is securing the server. The most common attack vector for internet facing servers is ssh root password bruteforcing (clicky), so moving away from both password usage for ssh logon as well as root login is a valid first step. Basically, it involves you following this guide: guide is here (choose your ubuntu version at the top right of that page, defaults to 14.04). If you're really paranoid about security you might want to generate your public/private key file on your local pc instead of on your server, use puttygen.
The next step in securing your ssh login is putting it on a different port. By default ssh listens on port 22, on ANY ssh installation. This means that portscans/brute force attacks will try port 22 first. Changing your ssh port basically boils down to editting /etc/ssh/sshd_config and changing the Port 22 line to some other port, preferably above 1024, but it must be below 65536 (I'm using a port between 30000 and 40000). Hereafter you have to restart your ssh deamon (ubuntu: service ssh restart) and reconnect your client on the new port.
After this, you should configure a firewall (example here). Keep in mind that changing your ssh port requires you to actually read the stuff at that link or you might lock yourself out of your server.
Step 2: Installing CoD2 prerequisites
CoD2 prerequisites are as easy as doing:
Although I'm not 100% sure that covers ALL the prerequisites. If cod fails to run, try installing the libcod prerequisites (step 4) as well.Code:sudo dpkg --add-architecture i386 sudo apt-get update sudo apt-get -y install libstdc++5:i386