Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # This tutorial is specifically for dropbox
- If you see something in <THESE> then you should replace the whole thing with whatever it is.
- For example, ssh root@<IP> would become ssh root@123.456.78.9 if 123.456.78.9 was your server's
- IP address.
- Make a new Ubuntu droplet. Add an ssh key (google search if you do not know how to do this) and
- make sure you use that instead of password login. Let it spin up then copy the IP address and
- do the following:
- # Log into the box as root
- ssh root@<IP>
- # Make a new Linux user
- adduser ace
- usermod -aG sudo ace
- rsync --archive --chown ace:ace ~/.ssh /home/ace
- # Firewall this bad larry
- ufw allow OpenSSH
- ufw allow 9000:9001/udp
- ufw enable
- # Log out of root and back in as the ace user
- exit
- ssh ace@<ip>
- # Install MariaDB
- sudo apt update && sudo apt upgrade
- sudo apt install mariadb-server mariadb-client
- sudo mysql_secure_installation
- # Follow the on-screen instructions for securing the db. You want to do everything it asks if you want to do ;)
- # Enter MariaDB
- sudo mariadb
- # Make a new user and make the tables we need.
- create user 'ace'@'localhost' identified by '<PASSWORD>';
- create database `ace_auth`;
- create database `ace_shard`;
- create database `ace_world`;
- grant usage on *.* to 'ace'@localhost identified by '<PASSWORD>';
- grant all privileges on `ace_auth`.* to 'ace'@localhost;
- grant all privileges on `ace_shard`.* to 'ace'@localhost;
- grant all privileges on `ace_world`.* to 'ace'@localhost;
- flush privileges;
- exit;
- # Install dotnet (this is a little fucky)
- wget -q https://packages.microsoft.com/config/ubuntu/19.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
- sudo dpkg -i packages-microsoft-prod.deb
- sudo apt-get install apt-transport-https
- sudo apt-get update
- sudo apt-get install dotnet-sdk-2.2=2.2.104-1
- (This errored for me and the microsoft debug shit was no good, I had to remove the version pin to run it.)
- (only do this if the above errors out for you like it did for me: sudo apt-get install dotnet-sdk-2.2)
- # Download the ACE server code to your server and get it ready to configure
- git clone https://github.com/ACEmulator/ACE.git
- cd ACE/
- cp Source/ACE.Server/Config.js.example Source/ACE.Server/Config.js
- # Grab the world data
- # Right click copy link for ACE-World-Database-v<WHATEVER>.sql.zip
- wget <URL for latest release https://github.com/ACEmulator/ACE-World-16PY-Patches/releases>
- sudo apt install unzip
- unzip <filename>
- # Seed the databases now
- mysql --user='<THE USER WE MADE ABOVE>' --password='<THE PASSWORD WE SET FOR THE USER ABOVE>' ace_world < '<PATH TO THE FILE YOU JUST UNZIPPED>'
- mysql --user='<THE USER WE MADE ABOVE>' --password='<THE PASSWORD WE SET FOR THE USER ABOVE>' ace_shard < 'Database/Base/ShardBase.sql'
- mysql --user='<THE USER WE MADE ABOVE>' --password='<THE PASSWORD WE SET FOR THE USER ABOVE>' ace_auth < 'Database/Base/AuthenticationBase.sql'
- # Apply shard and auth updates:
- touch update_the_dbs.sh
- vim update_the_dbs.sh
- # Paste this into the file by copying it and then pressing `i` inside vim then pasting it
- for filename in ./Database/Updates/Shard/*.sql; do
- echo "Uploading $filename to the matrix..."
- mysql --user='ace' --password='<THE PASSWORD>' ace_shard < "$filename"
- done
- for filename in ./Database/Updates/Authentication/*.sql; do
- echo "Uploading $filename to the matrix..."
- mysql --user='ace' --password='<THE PASSWORD>' ace_auth < "$filename"
- done
- # Then press `esc` followed by typing `:wq`
- # You should now be back in your console, let's run the script!
- sh update_the_dbs.sh
- # You should see a bunch of output about uploading files to the matrix
- # Get the DAT files onto your server
- # Personally, I zipped mine up and put them on my dropbox then used the share link that dropbox provides.
- mkdir DATS
- cd DATS/
- wget <URL to a zip of your dat files (client_cell_1.dat, client_portal.dat, client_local_English.dat)
- # If you used a dropbox share link you might run into an issue I did where the file was saved as some awful name with quotes
- # that unzip didn't seem to like. If this happens, just run the command
- # mv <terrible_file_name> acdats.zip
- unzip <whatever the name of the zip file you made and just downloaded is>
- # Don't need this any more so let's delete it to free up some space
- rm <the zip file>
- # Update the config
- cd ..
- vim Source/ACE.Server/Config.js
- # The most important things to change are the DatFilesDirectory setting
- "DatFilesDirectory": "~/ACE/DATS",
- # And then setting the IP to your server's public IP
- # Build the project
- cd Source/
- dotnet build
- # Follow the instructions on how to run the server which should be in here: https://github.com/ACEmulator/ACE/blob/master/README_linux.md
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement