Hello,
I thought I would contribute to a guide on how to setup a Dev Environment on VPS for Core3 or MtG Repo's for those interested in having available online. I'm relatively a newbie at this type of server hosting, so if anyone has any critique or expertise to contribute that would be great as well.
References:
Step one in the process to hosting a swgemu server on a VPS, is well... to get the VPS. For my service provider I rented a VPS from Contabo, https://contabo.com/en/, but there are many different VPS providers out there so look for one that suits you. I decided to go with Contabo for a few reasons: (1) Was relatively inexpensive, for $6.99/mo was able to secure a sever with 4 cores, 8gb RAM, 200gb SSD memory (2) Operating System supported - although swgemu can be installed on most Linux distributions I determined to use a provider that offered Ubuntu 20.04 to match the OS used by Neopixie's installation guide. (3) Geography, being located in California there is a surprising lack of VPS vendors that offer servers within the United States and on the West Coast. Most places I found have their servers in Canada for North America without having a specific West Coast presence - Contabo offered servers based out of Seattle, WA which results in about ~54 ping on my server being located in rural California.
So with that being said, please select a VPS service that works best for you.
2. Accessing the VPS
Once you've selected your VPS provider they should send you more information on your server. Important criteria including:
From this application, enter your External IP address provided to you by your VPS service provider. Make sure the Connection type is SSH and click open. This should open a terminal connecting you to your VPS. It will likely request you provide your username and password, which should also have been provided by the VPS provider during setup. Once you log into your VPS via PuTTY you'll now begin building the server.
3. Preparing the VPS
Now once you are logged into you VPS, and per recommendation of Neopixie you'll need to do some preliminary steps to ready your VPS environment to host your swgemu server. Enter the following commands into your PuTTY terminal.
4. Installing SWGemu or MtG Repo
This next step is where you'll begin building the SWG server of your choosing. At this point decide if you would like to install the MtG Repo or the SWGemu repo.
In the same terminal from step 3. above, enter the following commands.
git clone https://github.com/swgemu/Core3
EDITED Thank you to Lasko for the updated information regarding a vanilla Core3.
From Lasko below:
The Review repo is no longer used and might cause some confusion.
Engine and Core are now here: https://github.com/swgemu
OR
git clone https://github.com/ModTheGalaxy/mtgserver
This process takes a little time, so be patient and let it run. Once it's completed running you're now ready to officially build your SWGemu server. Change your directory to the MMOCoreORB by entering the following into the terminal:
cd ~/git/Core3/MMOCoreORB
Then enter the following command to build your sever.
make -j8
Please note, -j8 is referring to the number of Cores allocated on your VPS to installing the server. For my server I knew I only had 4 cores, so instead of entered make -j8, I entered make -j4. Match the number of available cores to your machine to install the server. When I first attempted to make my server at this point I encountered a boost error while running the last code. To fix this I reinstalled boost on my Ubuntu VPS by entering the following command in my Root depository. PLEASE NOTE: This is not a part of the install process, this was just a specific solution to an error I had while making the server.
sudo apt install build-essential libboost-system-dev libboost-thread-dev libboost-program-options-dev libboost-test-dev
After entering make -jX your server will begin to build and may take some time to compile. Once it's completed enter the following command to reboot your server with the SWG installation:
Sudo reboot
5. Installing a GUI for your OS on your VPS
At this point you may be ready to install a GUI on your VPS. Now that the SWG server has been installed your VPS you'll be ready to mod and play with it. To do so there are a few steps using your VPS.
In the General tab of your Remote Desktop Connection enter your external IP address in the Computer: logon settings and remote into your username, if you kept the same username as the installation commands above and click Connect. Once connected you should be greeted by a screen that looks like this:
AND BOOM, you have a VPS server with both a accessible GUI and SWGemu installed. But the installation process isn't over yet...
I thought I would contribute to a guide on how to setup a Dev Environment on VPS for Core3 or MtG Repo's for those interested in having available online. I'm relatively a newbie at this type of server hosting, so if anyone has any critique or expertise to contribute that would be great as well.
References:
- Neopixie's SWGemu setup guide - First and foremost this is the majority of the setup guide that will be used to create the server. I will summarize Neopixie's steps below but please read his guide carefully as well. (https://www.swgemu.com/forums/showthread.php?t=236411)
- Cloud Tech GUI setup guide - From the blank VPS environment I had struggled using an only text based PuTTY server creation and having the GUI aspect was important for modding and accessing file structures more conveniently. (
- Mod the Galaxy Repo - GitHub link to swgemu repository. Included reference to core3 as well if preferring to install vanilla environment. (https://github.com/ModTheGalaxy)
Step one in the process to hosting a swgemu server on a VPS, is well... to get the VPS. For my service provider I rented a VPS from Contabo, https://contabo.com/en/, but there are many different VPS providers out there so look for one that suits you. I decided to go with Contabo for a few reasons: (1) Was relatively inexpensive, for $6.99/mo was able to secure a sever with 4 cores, 8gb RAM, 200gb SSD memory (2) Operating System supported - although swgemu can be installed on most Linux distributions I determined to use a provider that offered Ubuntu 20.04 to match the OS used by Neopixie's installation guide. (3) Geography, being located in California there is a surprising lack of VPS vendors that offer servers within the United States and on the West Coast. Most places I found have their servers in Canada for North America without having a specific West Coast presence - Contabo offered servers based out of Seattle, WA which results in about ~54 ping on my server being located in rural California.
So with that being said, please select a VPS service that works best for you.
2. Accessing the VPS
Once you've selected your VPS provider they should send you more information on your server. Important criteria including:
- IP Address (including user and password to access server).
- VNC IP and Port (including password).
From this application, enter your External IP address provided to you by your VPS service provider. Make sure the Connection type is SSH and click open. This should open a terminal connecting you to your VPS. It will likely request you provide your username and password, which should also have been provided by the VPS provider during setup. Once you log into your VPS via PuTTY you'll now begin building the server.
3. Preparing the VPS
Now once you are logged into you VPS, and per recommendation of Neopixie you'll need to do some preliminary steps to ready your VPS environment to host your swgemu server. Enter the following commands into your PuTTY terminal.
- sudo apt-get update
- sudo apt-get upgrade
- sudo apt install build-essential libmysqlclient-dev liblua5.3-dev libdb5.3-dev libssl-dev cmake git default-jre
4. Installing SWGemu or MtG Repo
This next step is where you'll begin building the SWG server of your choosing. At this point decide if you would like to install the MtG Repo or the SWGemu repo.
In the same terminal from step 3. above, enter the following commands.
- mkdir -p ~/git
- cd ~/git
git clone https://github.com/swgemu/Core3
EDITED Thank you to Lasko for the updated information regarding a vanilla Core3.
From Lasko below:
The Review repo is no longer used and might cause some confusion.
Engine and Core are now here: https://github.com/swgemu
OR
git clone https://github.com/ModTheGalaxy/mtgserver
This process takes a little time, so be patient and let it run. Once it's completed running you're now ready to officially build your SWGemu server. Change your directory to the MMOCoreORB by entering the following into the terminal:
cd ~/git/Core3/MMOCoreORB
Then enter the following command to build your sever.
make -j8
Please note, -j8 is referring to the number of Cores allocated on your VPS to installing the server. For my server I knew I only had 4 cores, so instead of entered make -j8, I entered make -j4. Match the number of available cores to your machine to install the server. When I first attempted to make my server at this point I encountered a boost error while running the last code. To fix this I reinstalled boost on my Ubuntu VPS by entering the following command in my Root depository. PLEASE NOTE: This is not a part of the install process, this was just a specific solution to an error I had while making the server.
sudo apt install build-essential libboost-system-dev libboost-thread-dev libboost-program-options-dev libboost-test-dev
After entering make -jX your server will begin to build and may take some time to compile. Once it's completed enter the following command to reboot your server with the SWG installation:
Sudo reboot
5. Installing a GUI for your OS on your VPS
At this point you may be ready to install a GUI on your VPS. Now that the SWG server has been installed your VPS you'll be ready to mod and play with it. To do so there are a few steps using your VPS.
- Install a VNC viewer application; for my server connecting from a Windows desktop I installed UltaVNC Viewer. Here enter your VNC Server and Port address provided by your VPS provider and connect. After connection you may be prompted for a password which should already be included with your VPS information.
- Following re-open PuTTY after your latest reboot in Step 4, and begin installing the GUI OS to your system. To do so enter the following into the root of your terminal:
- sudo apt-get install ubuntu-desktop
- sudo apt install gnome-software
- sudo apt-get install xrdp htop
- sudo rm /usr/share/polkit-1/actions/org.freedesktop.color.policy
- sudo adduser remote
- Set your password of your choosing. I used "swg" for my password.
- sudo usermod -aG sudo,adm remote
- sudo reboot
In the General tab of your Remote Desktop Connection enter your external IP address in the Computer: logon settings and remote into your username, if you kept the same username as the installation commands above and click Connect. Once connected you should be greeted by a screen that looks like this:
AND BOOM, you have a VPS server with both a accessible GUI and SWGemu installed. But the installation process isn't over yet...
Attachments
-
98.1 KB Views: 75
-
28.3 KB Views: 62
-
21.7 KB Views: 72
-
50.3 KB Views: 71
-
42.7 KB Views: 75
Last edited: