External Server Guide

From Minehut Wiki
Jump to navigation Jump to search

What is an External Server?

External servers are servers hosted outside of Minehut that are connected to the Minehut proxy in order for them to use Minehut's advertising features. The original guide on how to setup an External Server can be found here.

External Servers are an advanced feature ⚠️

Setting up an external server may be challenging if you do not have experience configuring a proxy. In addition, since you are hosting your own server, the Minehut support team will have a limited ability to help with technical challenges or reporting player rule violations.

Getting Started in Three Steps

Minehut External Server Setup Steps.png

Connecting your external hosted Minecraft server to Minehut doesn't have to be difficult! If you would like to host your server elsewhere, or even self-host on a dedicated machine, you can still connect to Minehut and get all of the benefits of Minehut's hosted servers. Including:

  • Advertise to Minecraft players in our lobby, Discord, forums, and social media
  • DDoS protection
  • Hide your IP address to prevent direct attacks
  • Take part in Minehut events and videos/live streams
  • Join our Servers Discord to connect with other server teams

The process for setting up your external Minecraft server to connect to Minehut is broken down into three main steps, each with a small process to complete. At the end of this article, you will find additional optional settings that you can enable as needed.

Step 1. Create Your External Server

Minehut External Server Setup Step 1.png

External servers are servers hosted outside of Minehut. In order to connect an external server to Minehut, you first need to pick an external hosting provider and create a server on their platform. The instructions for doing this vary depending on your host, and you will need to figure this part out on your own.

Things to Consider

  • It's not necessary to have an external hosted server to connect to Minehut. We have great plans to host your server with us, and you don't need to follow the rest of this tutorial to use them!
  • An external server can be run as either a single standalone Paper server, or a proxy network with Velocity, Waterfall, or Lilypad. BungeeCord is not supported.
  • If you are new to setting up a proxy, we recommend starting with Velocity, which you can find instructions here to get going. Alternatively, instructions for Paper can be found here if you do not wish to run a proxy.

👍 Before continuing, make sure that you can connect to your server! Your host will provide a server address that you should test to make sure is working before you move to the next section.

Step 2. Configure Your External Server

Minehut External Server Setup Step 2.png

Before players can connect to your server through Minehut you will need to set up your server to use Minehut’s authentication service. Players will only be able to join if you complete this step.

Depending on the type of proxy (Velocity, Waterfall, or Lilypad) or server (Paper, etc...) you created in Step 1, follow the directions as listed below.

For part of this step you will need to edit the startup flags for your server or network, which might look similar to this example host. Check with your host to find out where to edit your flags.

Example Host Startup Flags.png

Velocity

Main article: Velocity

In velocity.toml under advanced, set haproxy-protocol = true (Note: Skip this velocity.toml edit if you’re using TCPShield)

Add the following CLI flag to your start script:

-Dmojang.sessionserver=https://api.minehut.com/mitm/proxy/session/minecraft/hasJoined

When you are done, your script may look something like the following:

java -Dmojang.sessionserver=https://api.minehut.com/mitm/proxy/session/minecraft/hasJoined -jar velocity.jar

BungeeCord

Main article: BungeeCord

This proxy type is currently not supported due to an issue in BungeeCord; please use Waterfall instead or switch to Velocity until this is resolved.

Waterfall

Main article: Waterfall

In config.yml under listeners, set proxy_protocol: true (Note: Skip this config.yml edit if you’re using TCPShield)

Add the following CLI flag to your start script:

-Dwaterfall.auth.url="<https://api.minehut.com/mitm/proxy/session/minecraft/hasJoined?username=%s&serverId=%s%s>"

When you are done, your script may look something like the following:

java -Dwaterfall.auth.url="<https://api.minehut.com/mitm/proxy/session/minecraft/hasJoined?username=%s&serverId=%s%s>" -jar waterfall.jar

Lilypad

Main article: Lilypad

Set the following environment variable:

LILYPAD_MOJANG_SESSIONSERVER_URL to https://api.minehut.com/mitm/proxy/session/minecraft/hasJoined

Paper

Main article: Paper

🗒️ Note: These instructions only apply if you are running Paper standalone and NOT under a proxy. If you are using Velocity, Waterfall, or Lilypad, you should have already configured this and you can safely skip this Paper section.

In config/paper-global.yml under proxies, set proxy-protocol: true (Note: Skip this paper-global.yml edit if you’re using TCPShield)

Set enforce-secure-profile to false in your server.properties file.

Add the following CLI flags to your start script:

-Dminecraft.api.auth.host=https://authserver.mojang.com/ -Dminecraft.api.account.host=https://api.mojang.com/ -Dminecraft.api.services.host=https://api.minecraftservices.com/ -Dminecraft.api.session.host=https://api.minehut.com/mitm/proxy

When you are done, your script may look something like the following:

java -Dminecraft.api.auth.host=https://authserver.mojang.com/ -Dminecraft.api.account.host=https://api.mojang.com/ -Dminecraft.api.services.host=https://api.minecraftservices.com/ -Dminecraft.api.session.host=https://api.minehut.com/mitm/proxy -jar paper.jar

Step 3. Connect Your Minehut Service to your External Server

Minehut External Server Setup Step 3.png

Before you can do step 3, make sure you've completed steps 1 and 2 above.

Create a Minehut Account

Go to Minehut and create an account. You’ll use this account to manage your server.

Set Your Server Plan to “External”

  1. Go to your server (or create a new one)
  2. Activate your server and open the Server Panel by clicking “Manage”
  3. From your Server Panel, edit your server plan
  4. Set your server plan to “External” and press confirm
  5. You’re now ready to add your external server

🗒️ Note: You will need to buy credits to use an external server and keep it active. The easiest way to make sure you have enough credits every month is to purchase a credit subscription.

Complete External Server Settings

On Minehut, open your server’s server panel and navigate to the “External Server Settings” section.

External Server Settings.png
Complete All Fields
Field Description
IP Enter the public IP of your external server.

Your host will normally provide you with the public IP, which typically are four numbers separated by dots (for example 123.45.67.89). This information is usually visible somewhere within the server panel.

A domain name can also be used here if you have one (for example play.myserver.com configured as an A record pointing to 123.45.67.89).

If you are using TCPShield, this will instead be your DDoS-protected IP that they provided.

Proxy Type Select the type of proxy you’re using.

This will be “Velocity” or “Waterfall” if you are using either. If using anything else (for example, a standalone Paper server) select “Other”.

DNS Record Type Select the type of record used for your server.

Use “Port” if you are using a public IP address, DDoS-protected IP, or are using a domain that does not use an SRV record.

Use “SRV” only if you use an SRV record on your server. If you are not using an SRV record or have a misconfigured SRV record, selecting this will break your server.

Port The port used to connect to your external server.

The default Minecraft port is 25565 but many hosts will assign you a different port, so you should check to make sure. Normally the port is displayed in the same place as the IP. Players will not be able to connect if the port is wrong.

TCP Shield Select whether you have configured TCP Shield for DDoS protection.

Most servers should leave this as "Not Configured" as most hosts already have built-in DDoS protection.

Select "Configured" only if you have configured your external server on TCPShield.com, or this will break your server.

Optional Settings

Add A Custom Domain (optional)

You can set up a custom domain to allow players to directly join your server from the Minecraft server list without needing the <server>.minehut.gg sub-domain provided to you for free by Minehut.

To do this, you will need a domain that you have already purchased through a domain name registrar of your choice.

Once you have a domain name chosen, follow these steps to add your custom domain to your external server:

  1. In the settings dashboard of your external server, navigate to “Custom Domains”.
  2. Click “Add Domain”.
  3. Follow the directions displayed to verify ownership of your domain.
  4. Click “Verify Domain”.
  5. If all has gone well, your domain should now be connected successfully.

We have another wiki page that's all about using your custom domain for your server. In that tutorial, we cover the following steps:

  • Verifying your domain on our website with a TXT record
  • Creating a CNAME record for Java connectivity
  • (Optional) Creating both an SRV and CNAME record for Java and Bedrock connectivity

Add Your Resource Pack (optional)

Main article: Resource Packs

You can set up a resource pack by linking to your resource pack in your server’s server.properties file. In order to protect users, Minehut only allows resource packs hosted on designated domains:

In your server.properties file, you need to set the following properties:

  1. Set resource-pack= to your resource pack link
  2. Set resource-pack-sha1= to your resource pack hash (optional, learn more)

For external servers, uploading resource pack files directly in the server panel is not yet supported.

Set up TCPShield (optional)

TCPShield provides additional DDoS protection for servers. Keep in mind that normally if you are proxying through Minehut this will not be necessary since you will be protected behind Minehut’s network. To use TCPShield you will need to make some additional changes to the configuration in the Minehut panel as well as the TCPShield panel.

A custom domain is required to set up a TCPShield external server.

In TCPShield:

  1. Go to https://panel.tcpshield.com/register and sign up for an account or log in if you already have one.
  2. Add a network with a name of your choice.
  3. Navigate to “Backends” and set up your proxy server by adding a set with your proxy IP.
    1. Make sure you leave “Proxy Protocol” here as “Disabled”.
  4. Navigate to “Domains” and verify your custom domain.
  5. Navigate back to “Backends” and click “Add” for the backend you created earlier.
  6. Scroll back up and follow the steps provided.

In your External Server Settings: IP: Use the domain pointing to the CNAME record as the IP. TCPShield: Select “Configured Externally”.

Save your changes, and if everything was done correctly your external server should now be properly configured behind TCPShield!

Customize Your Server’s Appearance (optional)

After you’ve completed all the previous steps, you’re ready to share your server with the Minehut player base. Polish your server’s appearance (how it displays in Minehut) by customizing the following:

  • Server Name
  • Server Icon
  • Message of the Day (MOTD)
  • Categories
  • Visibility

Promote Your Server (optional)

Share on Twitter, Discord, TikTok, and Elsewhere

Let people know that your server is on Minehut. This will help players organically discover your server.

Server Ads in the Advertising Tab

From your server’s server panel, navigate to the “Advertising” tab. Here you can purchase ads that promote your server in the in-game server list. Minehut Server Ads

/ad with Ranks

From the Minehut Lobby, you can type /ad to promote your server in the lobby chat. Access more /ad functionality by purchasing ranks.

Rules and Guidelines

Due to the nature of how externally hosted servers work when connected to Minehut, Minehut staff are unable to widely moderate or act on behaviors that occur on those servers. External servers are welcome to access Minehut's network and share in their player community experiences, as well as advertise to players to join them, as long as they adhere to the following rules:

  1. Follow all the rules and guidelines as outlined on the community rules page as if you are an internally hosted Minehut community server.
  2. Only use the officially supported method for connecting your external server to the Minehut network. Other methods may be deprecated, removed, patched out, or seen as a rule violation if they disrupt other Minehut community experiences.
  3. Do not create multiple server listings in Minehut which point to the same external server. Multiple server listings can be created for the same network so long as the resulting location is an entirely different setting and gameplay than others you link to. Example: You cannot create three servers in Minehut which all link to the same lobby on your external network.
  4. External servers are held to a high standard for behaviors that can result in harm done to players, such as (but not limited to) creating an environment where players feel free to act in sexually suggestive or inappropriate ways, use server-created gambling mechanics, get involved in witch hunts or doxing schemes, building discriminatory content into their server features, or encouraging strong profanity in the public chats.
  5. If an external server is suspended from Minehut, that server has lost the privilege to connect to the Minehut community and cannot create alternate servers or accounts to attempt to evade the punishment.
  6. Do not instruct players who join via Minehut to leave Minehut’s network to connect directly to your external server address.