-
Notifications
You must be signed in to change notification settings - Fork 18
nodeGame on DigitalOcean
Please create an account on Digital Ocean using this referral link: https://m.do.co/c/77e0cad8a86b.
You will get 100USD credit to spend during the first two month and you will also contribute to cover nodeGame's hosting expenses at no extra costs for you (please notify us if the amount of credit is different).
After having registered, you can create a new Digital Ocean server ("droplet") for nodeGame with just a few clicks using the Marketplace app. On the side menu on the right, under the Discover header, click on Marketplace, then type nodeGame in the search box.
In the next page, select "Create NodeGame Droplet."
Next, you need to specify your droplet's settings. If unsure, you can follow the guidelines below.
-
Choose the cheapest Droplet (5USD per month). Remember, you will be charged only for the time you actually use it. For instance, if you use it for one day and then dispose it, you will be charged approximately 16 cents.
-
Choose the hosting data center according to your targeted population. For instance, If you plan to mainly reach an American audience, you could pick the NYC data center.
-
Add additional services, such as backup, as needed (extra charges may occur).
-
Choose if you want to use a password or a SSH key to login into your Droplet. Using a password requires no additional configuration, but using an SSH key is safer and faster. If you decide to go for the SSH key please follow this guide.
Once created, you need to ssh into your droplet once to activate it. Open a terminal (e.g., Git Bash) and type:
ssh root@DROPLET_ADDRESS
(where DROPLET_ADDRESS
is the ip address of your droplet that you
can find in the dashboad).
If successful, you should see something like:
After you created your nodeGame droplet, you may upload your game
inside the games/
directory of the nodeGame server. You have two
options:
-
If your game is on an online git repository (e.g., GitHub): open a terminal (e.g., Git Bash) and login into your Droplet. Navigate to the
games/
folder inside the nodeGame installation directory and type:git clone GIT_ADDRESS
(where
GIT_ADDRESS
is the address of your git repository). -
If your game is on your local computer: open a terminal (e.g., Git Bash) and navigate to the
games/
folder inside your local nodegame installation directory and type:scp -r YOUR_GAME root@DROPLET_ADDRESS:nodegame-vXXX/games/
(where
YOUR_GAME
is the name of the directory containing your game,DROPLET_ADDRESS
is the address of your Droplet, andXXX
is the actual nodegame version number).
-
Stop the server:
pm2 stop launcher
-
Start your game as default:
pm2 start launcher.js -- --default YOUR_GAME
If you feel adventurous, you can manually install nodeGame from scratch.
Go back to the wiki Home.
Copyright (C) 2021 Stefano Balietti
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.