How to Upload a Custom Jar to Multicraft

How-To's

Content

  • Users and Players
    • Assign Different Roles to Users
    • Bachelor User Roles
  • Whitelisting / Private Servers
  • Commands
    • Built-in Commands
    • Running Scripts
    • Special Scripts
    • Examples
  • Custom JAR Files
    • Determining which .conf file to utilise
    • Default settings for all JARs
    • CanaryMod
    • Tekkit/FTB
    • Forge
    • StarMade
    • PocketMine-MP
    • Spigot and BungeeCord
    • Bedrock alpha
    • User Contribution: Updating BuildTools and Spigot (Windows Standalone)
  • Server Templates (new in 2.0.0)
    • Modernistic automobile-setup
      • Suggesting templates for JARs
      • Automatically installing templates
    • Examples
  • Using MySQL / Decision-making a remote server
    • Configuring the Daemon
    • Configuring the Panel
    • Configuring MySQL
      • Secure MySQL
      • Modify the Mind Address
      • Grant Access to Daemon MySQL Users
      • Open Firewall / Router for MySQL
  • Cloud Installation / Mass Deployment
  • Adding Region Logroller support
  • Changing the port of the standalone webserver (Windows)
  • How do I get FTP access to my server?
  • Accepting the Minecraft EULA
    • For individual servers
    • For server providers
      • Case one - Add a config file entry
      • Example ii - Add an "Accept EULA" button to the server settings (advanced)
      • Case 3 - Automatically create the file (advanced, Linux multiuser merely)
  • Optional User Selectable Server Startup Parameters (new in 2.0.0)
  • Limit Disk Space / Quota Support (Linux only, new in 2.0.0)
    • Configure Linux Quota
  • Configure User Friendly URLs
  • Alter the Panel Management
  • Send mails using SMTP instead of PHP mail()
  • Daemon Callbacks (new in 2.0.0)
  • Windows Standalone: Update Java
  • Different Java Versions

Users and Players

Multicraft makes a difference between users and players. Users are registered command console users that can apply various functions depending on their access rights for a specific server. Players are created as soon as they are seen past a minecraft server. Each server has a split up list of players.
Players tin can be assigned to users. By doing and then the player inherits the function of the user. The players role can also be adjusted without linking it to a user so it is optional for players to register.

Assign Dissimilar Roles to Users

You can assign different roles to users, either per-server or globally:

  • To assign a part to a user for a single server you lot can go to the settings page of that server and then nether "Advanced"->"Users" you lot can expect up the user and change the office.
  • To assign a role globally you lot tin can go to the user contour under "Users" and so change the "Global Function" setting. The role assigned here applies to all servers in the panel and so if a user has the global role "Administrator" they will exist admin for all servers.

Bachelor User Roles

The following list of available roles is in ascending order, meaning the listed roles include the capabilities of all of the roles above them:

  • Invitee
    Can meet basic information about a server similar online status and number of players
  • User
    Tin can use chat, view available commands and use sure cheat functionality if enabled by the server owner
  • Moderator
    Can start servers, use the "admin say" command, encounter the server console, summon/kick/tp players, use the "give" command and download backups
  • Super Moderator
    Can issue server commands, stop/restart the server and first backups
  • Ambassador
    Has full control over all server functions such equally managing players, editing configs, etc.
  • Co-Possessor
    Can assign FTP access to other users
  • Possessor
    Tin can assign co-owner status to other users
  • Staff (Global Role merely)
    Has superuser admission to all servers
  • Superuser (Global Office but)
    Has total superuser access to the entire console and the panel settings

Whitelisting / Private Servers

To make a server private but set its "Default Role" to "No Access". The default role is the role assigned to all users/players that don't have any other role assigned to them.
To allow admission for a player to a private server y'all tin either create the player with a role greater than "No Admission" or edit the player entry if it already exists.

Commands

You can define new chat commands or change the part required to run born commands.
The "Prerequisite" field in the control create/edit course refers to another command that has to be run before this one. Commands fail silently if the user doesn't take the required office.

To run a control the thespian needs to have a role greater than or equal to the one divers in the control settings and say the cord defined in the "chat" setting of the command in-game. To run the command silently (i.e. without printing it in the conversation) it can be prefixed with a slash, however, this does not work with all Minecraft versions.

asay Hi everyone!        

When creating a new custom command y'all tin can define what is run on the Minecraft server by changing the "Run" field. If the command is preceded by "multicraft:" the command that volition be run is the Multicraft control that has the "Conversation" field matching the specified cord, see the MOTD example below. The following special sequences can be used in a control:

%n The players proper noun
%1, %two, etc. Every %10 gets replaced by the X-th argument the player supplied (arguments are infinite separated)
%south The whole statement string supplied. If %s is used multiple times the statement string is split by spaces every bit many times equally there are %south arguments
%l The players admission level
%o Empty string (can exist used to separate %one, %2, etc. from a number)

Multiple commands can be separated using a semicolon ";". To escape the semicolon use a backslash "\;". Have care not to insert a space before a command (i.e. after the semicolon) equally Minecraft won't interpret that.

Built-in Commands

Congenital-in commands can be chosen - just like Minecraft console commands - past using them in the "Run" field.
You can also provide parameters in the "Run" field already, for example a command with "builtin:tell_level admin" in "Run" will crusade a message to be sent to every player who is an admin. The player doesn't have to specify the level himself because it's already provided.

Command Parameters
builtin:asay message Prints "message" every bit the server
builtin:fill-in Creates a new backup zip file
builtin:engagement Prints the current date
builtin:give id [corporeality] Gives the player the particular with id "id". If amount is not specified 64 blocks are given.
builtin:kick target Kicks "target" from the server
builtin:list Tells the list of players on the server to the player
builtin:restart Restarts the server
builtin:restart_empty Restarts the server only if no players are online
builtin:save Saves the world
builtin:saylist Prints the list of players on the server to everyone
builtin:script name Runs the script "name". The script has to be defined in the scripts.conf file
builtin:start Starts the server
builtin:finish Shuts down the server
builtin:stop_empty Shuts downwards the server if no players are online
builtin:summon target Teleports "target" to the histrion
builtin:tell_level level message Tells "message" to all players with their level greater than or equal to "level". "level" can exist numeric or one of: user, mod, admin, owner
builtin:fourth dimension Prints the current fourth dimension
builtin:tp target Teleports the histrion to "target"
builtin:tp_other player1 player2 Teleports "player1" to "player2"
Running Scripts

The congenital-in control "builtin:script" enables the users to run scripts you have defined for them in a special config file. By default this config file is chosen "scripts.conf" and expected to be in the Multicraft base directory (where the multicraft.log lies). You lot can change the path/name of this file in your multicraft.conf.
The format of the file is:

[cmd1] servers=all command={BASE_DIR}/script1.sh  [cmd2] servers=two,3,7 command={BASE_DIR}/script2.sh  [dangerous] servers=1 command={SERVER_DIR}/userscript.sh        

The value in the [] brackets is what the user puts subsequently "builtin:script". "servers" lists the server IDs of all servers that can run this command ("all" for all servers). "command" is the path to the script to run. The final control is chosen "unsafe" considering it runs a script that lies in the server directory which means that the user can change this script.

The following placeholders can be used in "command":

Placeholder Case
{BASE_DIR} /home/minecraft/multicraft The base Multicraft installation directory
{DAEMON_DIR} /home/minecraft/multicraft/bin The path to the Multicraft daemon executable
{DATA_DIR} /home/minecraft/multicraft/information The path to the daemon database (if using SQLite)
{JAR_DIR} /home/minecraft/multicraft/jar The path to the JAR directory
{SERVERS_DIR} /home/minecraft/multicraft/servers The directory that contains all the server base directories
{SERVER_ID} 6 The server ID of the server running the command
{SERVER_DIR} /home/minecraft/multicraft/servers/server6 The base of operations directory of the server running the control
{WORLD} world The proper name of the current world
{JAVA} java The default Java executable
{START_MEMORY} 1024 The amount of memory allocated on server startup
{MAX_MEMORY} 1024 The memory limit for this server
{JAR_FILE} minecraft_server.jar The JAR file used by this server
{JAR} /home/minecraft/multicraft/jar/minecraft_server.jar The full path of the JAR in utilise
{IP} 192.168.ane.24 The IP of the server
{PORT} 25565 The port of the server
{MAX_PLAYERS} 16 The number of player slots for this server
{DAEMON_ID} ane The ID of the daemon decision-making this server
{PID} 2589 The process ID of the running server procedure
{PID_FILE} /home/minecraft/multicraft/servers/half-dozen.pid The file containing the servers process ID

In the script itself you lot'll accept access to the same values listed above through environment variables. The base directory, for example, tin be output using

echo Base directory: $BASE_DIR        
Special Scripts

The post-obit script names are reserved as they accept special functions:

Script name
setup This script is run when a server is initially setup. This only works when the daemon is online at the fourth dimension the panel issues the command to run this script
_started This script is run as soon as the server has finished its startup sequence.
_stopped This script is run afterward the server has been stopped.
Examples
  • Verbose kick
    Chat kickmsg
    Run say %n: Boot %1 (%2);kicking %1
    "Admin" says:
    kickmsg Duke "Foul linguistic communication"            
    Upshot: The histrion "Knuckles" gets kicked and anybody sees the message "Admin: Kick Duke (Foul language)".
  • Give multiple items
    Chat armor
    Run give %n 310;give %northward 311;give %n 312;give %due north 313
    "Admin" says:
    armor            
    Result: The player "Admin" receives a full diamond armor gear up.

  • List online players in MOTD (message of the solar day)
    Conversation motd
    Run multicraft:listing
  • Running a PHP script on an external server regularly
    First yous need to define a section in your "scripts.conf":
    [extphp] servers=all command={BASE_DIR}/extphp.sh            

    Then you lot demand to create the script you reference in the config file:
    #!/bin/sh /usr/bin/wget -qO- "http://www.example.com/myscript.php?server_id=$SERVER_ID"            
    This script needs to exist executable by the Multicraft user.

    Next, ascertain the command:

    Chat (empty because you don't want to run this by conversation)
    Run builtin:script extphp
    Then create a new scheduled task and select the newly created command.

Custom JAR Files

We do not take whatsoever responsibility for whatever of the links used in this and the following sections regarding custom JARs. These links are provided by the JAR authors themselves and they are non checked by us

All that is required to utilise a different server JAR is to place the file in the "jar" directory of your Multicraft installation so prepare the "JAR File" field in your server settings to the name of the new file.
This will piece of work fine for a vanilla Minecraft JAR, withal, Craftbukkit JARs and other mods require different settings as their console output differs from the one of vanilla Minecraft. Also, just placing the JAR file in there will not make it appear in the JAR pick so users tin't select it.

This is where the ".jar.conf" files come into play. These files are used to make up one's mind the JAR file selection in the server settings and they are also capable of completely reconfiguring the output that Multicraft expects from the server. They are flexible enough to even run different Games with the correct settings.

For nigh users the supplied .jar.conf files will exist plenty. If you put a new Craftbukkit JAR in identify you can just re-create the existing "craftbukkit.jar.conf" to a new proper noun, e.yard. "craftbukkit_dev.jar.conf" and then edit the .conf file to friction match the new JAR settings. The most important setting to change would be the "name" setting and then information technology can be distinguished from the other JARs in the pick. The "source" and "configSource" settings should also exist changed to make sure it's not overwritten with the files listed in the sometime .conf. The "source" setting defines where the JAR is downloaded when the update function in the console is used, the "configSource" setting defines where the .conf file tin update itself from (if yous don't change that your .conf volition be overwritten with whatsoever is institute under "configSource" the adjacent fourth dimension you update the .conf file).

Most of the settings in the .conf files are documented directly in the comments of the default craftbukkit.jar.conf files supplied with Multicraft. For advanced use of these files please run across the ".jar.conf Files" Documentation page.

Defining which .conf file to apply

Past default Multicraft will use a conf file with the same name as the JAR file used. For example, using "minecraft_server.jar" will use the .conf file "minecraft_server.jar.conf".
With the 2.0.0 release Multicraft supports using .conf files by matching the JAR name against a regular expression. Y'all can find the full documentation of this feature in the "server_configs.conf.dist" file that ships with Multicraft. Simply rename this file to "server_configs.conf" and edit it to suit your needs. No daemon restart is required for these changes to take consequence.

Case:

[match] canarymod.jar.conf=canary

This will utilize the file "canarymor.jar.conf" for whatever JAR file that contains "canary" in the name.

Default settings for all JARs

Starting with 2.0.0 Multicraft volition read the default settings to use for all JARs from the config file "default_server.conf". You can rename the "default_server.conf.dist" that ships with Multicraft to "default_server.conf" and edit the file to your needs to override the default values. Whenever no .conf file is found or the .conf filed doesn't explicitly set a value the values from this file will be used.

CanaryMod

Yous can but download the canarymod.jar.conf file and place it in the "jar" directory of your daemon to be able to use CanaryMod like Craftbukkit or vanilla Minecraft.

Alternatively you lot can direct add together CanaryMod in your console using the following values nether Settings->Update Minecraft->Add together or Remove Files:

The "File URL" is:

http://dl.visualillusionsent.internet/minecraft/CanaryMod/latest.php        

The "Conf URL" is:

http://www.multicraft.org/download/conf/?file=canarymod.jar.conf        

Tekkit/FTB

Tekkit/FTB and similar mods tin be run using the craftbukkit.jar.conf merely please notation that they are not officially supported at the moment. Co-ordinate to user feedback, the following instructions can be used to set up such a server:

  • Make sure your .conf files for Craftbukkit are up to engagement under Settings->Update Minecraft
  • Copy the craftbukkit.jar.conf to Tekkit.jar.conf or ftbserver.jar.conf or similar (note that these file names are example sensitive)
  • Edit the new .jar.conf and change the setting "name" to how you want it to appear in the JAR dropdown
  • Set the "config" and "configSource" settings to empty as there are no official download locations for the JAR or the .conf
  • Download the Tekkit/FTB package
  • Put the jar from the downloaded package into the daemon "jar" directory, next to the .jar.conf yous but created (make certain they are named the same, e.g. Tekkit.jar and Tekkit.jar.conf)
  • If the mod needs boosted files to run extract the mod zip file into the server directory where you intend to use the mod
  • Make sure the files you have just extracted accept the correct owner, information technology needs to exist mcX:mcX, where X is the server ID
  • Select the new JAR in the drop downward for the server you lot have extracted the files to and start the server

Video Tutorial
Jacklin213 has created a YouTube video detailing the process of installing Tekkit with Multicraft.

Forge

Forge can exist run using the craftbukkit.jar.conf with a few modifications but please note that it's not officially supported at the moment. According to user feedback, the following instructions can exist used to set up such a server:

  • Make certain your .conf file for Craftbukkit is up to date under Settings->Update Minecraft
  • Copy the craftbukkit.jar.conf to forge.jar.conf like (annotation that these file names are case sensitive)
  • Edit the new .jar.conf and change the setting "name" to how you want information technology to appear in the JAR dropdown, e.g. "name = Forge"
  • Fix the "config" and "configSource" settings to empty as at that place are no official download locations for the JAR or the .conf
  • Set the "control" setting to the post-obit:
    command = "{Coffee}" -Xmx{MAX_MEMORY}M -Xms{START_MEMORY}M -Djline.terminal=jline.UnsupportedTerminal "@{JAR_DIR}/forge/unix_args.txt"            
  • Download the Forge installer
  • Run the following commands, supervene upon VERSION with the Forge version used and adjust paths as needed:
    # Run Forge installer java -jar forge-VERSION-installer.jar --installServer=/home/minecraft/multicraft/jar/forge/ # Copy unix_args.txt to jar/forge folder find /abode/minecraft/multicraft/jar/forge/libraries/ -proper noun 'unix_args.txt' -exec cp "{}" /home/minecraft/multicraft/jar/forge/ \; # Adapt paths in unix_args.txt to load libraries from the daemon "jar" directory sed -i 's,libraries,/home/minecraft/multicraft/jar/forge/libraries,g' /dwelling/minecraft/multicraft/jar/forge/unix_args.txt

StarMade

StarMade can be run using the StarMade.jar.conf file below only please notation that StarMade is not officially supported at the moment. Co-ordinate to user feedback, the following instructions can be used to set upwards a StarMade server:

  • Download the StarMade.jar.conf and place it in the jar directory of your daemon
  • Download and update the StarMade server
  • Put the StarMade.jar from the StarMade server into the daemon "jar" directory, next to the StarMade.jar.conf yous simply put in place
  • Put the residual of the files from the StarMade directory of the StarMade server into the server directory where y'all intend to use StarMade
  • Make sure the files you take but extracted accept the correct possessor, it needs to be mcX:mcX, where 10 is the server ID
  • Download starmade.sh and place it in the scripts directory of your daemon
  • Chmod the starmade.sh to 755
  • Select the StarMade JAR in the drop down for the server you take extracted the files to, salvage and restart

PocketMine-MP

PocketMine-MP tin can be run using the pocketmine.phar.conf file below. Thank you to Shoghi from pocketmine.net for providing this file!
The following instructions can be used to starting time a PocketMine-MP server:

  • Download the pocketmine.phar.conf and place information technology in the jar directory of your daemon
  • Download and install PocketMine into the directory "jar/pocketmine" of your daemon (the goal is to accept PHP installed at "jar/pocketmine/bin/php5/bin/php")
  • If yous accept not compiled PHP you can modify the PHP path in the pocketmine.phar.conf to the PHP binary you want to utilize (it's the first argument in the "command" setting)
  • Select the PocketMine JAR entry in the drop down for your server, save and restart
  • You can too update the pocketmine.phar file through the panel under Settings->Update Minecraft
  • If you see a setup sorcerer in the console instead of the normal server startup you tin simply send "Y" twice as a console command

Spigot and BungeeCord

Y'all can simply download the spigot.jar.conf or bungeecord.jar.conf file and place it in the "jar" directory of your daemon to exist able to use Spigot/BungeeCord like Craftbukkit or vanilla Minecraft.

Alternatively you can directly add Spigot/BungeeCord in your panel using the following values under Settings->Update Minecraft->Add or Remove Files:

In the first field enter either "spigot.jar" or "bungeecord.jar". Leave the "File URL" empty and for the "Conf URL" enter one of the following depending on the JAR you wish to install:

http://www.multicraft.org/download/conf/?file=spigot.jar.conf        

or

http://www.multicraft.org/download/conf/?file=bungeecord.jar.conf        

Y'all can then get to Settings->Update Minecraft, select the new entry and update the "JAR" file commonly.

Boulder blastoff

Linux

  • Place the following files in your daemon "jar" directory: bedrock.jar.conf bedrock.sh
  • Brand certain the "boulder.sh" file is executable (chmod 755)
  • Create a directory "boulder" in the "jar" directory
  • Excerpt the contents of the official bedrock server zip file into this new "bedrock" directory
  • Make certain the "rsync" command is bachelor on your organization

Windows

  • Place the following files in your daemon "jar" directory: bedrock_windows.jar.conf bedrock.bat
  • Rename the "bedrock.txt" file to "boulder.bat"
  • Create a directory "bedrock" in the "jar" directory
  • Excerpt the contents of the official bedrock server zip file into this new "boulder" directory

User Contribution: Updating BuildTools and Spigot (Windows Standalone)

Disclaimer: These are user contributed items, neither multicraft.org/xhost.ch GmbH nor the providing party assume any warranty any for any upshot as a result of using any of the listed scripts, programs, instructions or other items.

BuildTools and Spigot update script by RedstoneFiend

Make sure to edit the script and change "C:\Bitnami" to the path to your Bitnami installation directory. Too, the "Updater" directory needs to be created inside this directory earlier running the script.

Server Templates (new in 2.0.0)

The server template characteristic has been added in Multicraft two.0.0 to arrive easier to deploy mods and pre-installed servers. Templates can consist of files and scripts that are used to initialize the server directory.

The basic role of a template is to provide a set of files that will be copied to the server directory before the server starts. To achieve this all you have to do is to create a new folder in the "templates" directory of your daemon (by default "/home/minecraft/multicraft/templates") and put all files you lot desire to have copied to a server into the "files" directory within your new template folder.

You can also create a template.conf file and employ it to give your template a user readable name and configure some other settings such as the JAR file setting the server should be set to later using this template. The template.conf of the example template supplied with Multicraft (in the binder "cleanmodsplugins") contains extensive documentation of all bachelor settings in the comments.

A more avant-garde template tin as well run scripts at various steps in the template setup process. Please see the readme.txt in the "templates" directory of your daemon or in the Multicraft package for more information on this feature.

Modern auto-setup

Certain mods crave boosted files to work correctly. Using a uncomplicated template you can make Multicraft automatically copy the files into the server directory when the sever starts. By default the template will however have to exist selected for installation past the user. There are ii additional steps you lot tin have to change the behavior of automated mod setup:

Suggesting templates for JARs

To make sure the user knows about the correct template for a selected JAR you lot can utilize the "suggestTemplate" setting in the .jar.conf file of your JAR file, for example:

[settings] suggestTemplate = template1

This will ask the user to use the sample template and forward them to the "Setup" folio with the correct values already filled in.

Automatically installing templates

Instead of having the user confirm the tempate to install you tin also silently force the template to be installed whenever the server is switched to a JAR by using the "forceTemplate" setting in the .jar.conf file of your JAR file, for example:

[settings] forceTemplate = template1

Yous can modify the behavior using two additional flags:

  • always Causes the template to be installed on every server start instead of just the start start after switching to the JAR
  • delete CAUTION: Causes all server files to be deleted when the template is installed

These flags can also be combined, for example "ever,delete". To have a template named "template1" be installed on every server start, the setting would be:

forceTemplate = template1|always

Examples

Elementary templates for installing boosted mod files
In it's simplest grade a template is merely a directory that contains a "files" directory with any kind of files in it. Upon installation of the template the files in the "files" directory will be copied to the server directory. The proper noun of the template is the name of the directory within your "templates" directory. For example, two templates named "template1" and "template2" might look like this:

To take a JAR file install "template1" when that JAR file is selected, set the following in the .jar.conf file:

forceTemplate = template1

In this example that would crusade the file "Modern FILES Hither" to be copied to the server directory the starting time time the server is started using this JAR.

Copy an boosted test.conf file to the server directory

copyfile.zip/                           # Can either be a zip file or a plain directory              template.conf              # The template configuration, optional              files/                     # Everything in here will be copied to the server directory                    exam.conf

template.conf contents:

[general] name=Re-create exam.conf

Configure the server with an additional config file, print a message earlier installing the template, do post processing using a script, enable certain server startup parameters, disallow deleting the server directory as part of the template installation

configure.zip/               afterSetup.sh             # This script will be run later the setup has been completed               template.conf               files/                     some_config.conf

template.conf contents:

[full general] name=Configure Server for Modernistic setParams=1,3  [setup] neverDelete=truthful  [commands] initialize=/bin/echo Server Configuration set to Modern

Re-create additional mod files to the server and set the JAR file of the server to apply that new modern

craftbukkit.zip/                                     template.conf                 files/                       Additional mod files required

template.conf contents:

[general] name=Install Craftbukkit setJarFile=craftbukkit.jar

Using MySQL / Controlling a remote server

The Multicraft control panel can connect to a daemon running on a remote machine. To enable this you accept to use a MySQL database to which both the control panel and the daemon on the remote machine tin connect.

Configuring the daemon

Edit your "multicraft.conf" and set the "database" setting to the shared MySQL database. Be sure to also fill in the "dbUser" and "dbPassword" settings. For example if your MySQL server is running on 1.2.3.4:

database = mysql:host=1.two.iii.4;dbname=multicraft_daemon dbUser = *your MySQL user* dbPassword = *your MySQL password*

Replace the database name (here "multicraft_daemon") and the user and password appropriately.

By default the daemon listens on the IP address "127.0.0.ane" which ways only connections from the local machine will exist allowed. To allow the panel to connect to the daemon from the exterior edit your "multicraft.conf" and change the "ip" setting to the internet IP. If the daemon is running behind a router, set "ip" to 0.0.0.0 and "externalIp" to your external IP. For example, if the cyberspace accost of your daemon motorcar is 2.iii.4.five:

ip = 2.3.4.v

After changing the "ip" setting anyone tin can connect to it so make sure to set a strong daemon password in your "multicraft.conf" using the "countersign" setting, for case:

password = *potent daemon password*

Annotation that in the console configuration instructions below we'll refer to this password in the final stride of the installer.

Configuring the panel

If yous even so have the installer (install.php) in place you can re-run information technology and nether "Daemon Database" put in the information of the shared database. If y'all've already deleted the installer script you can manually edit the file "protected/config/config.php" and gear up "daemon_db", "daemon_db_user", "daemon_db_pass" to friction match the information you lot have put in your "multicraft.conf".

If the database is not yet initialized you can utilise the installer (install.php) to initialize it.

The same daemon password you have put in your multicraft.conf has to be used on the panel as well, you tin either change the setting "Countersign for daemon connection" in the last step of the installer or you can manually edit the file "protected/config/config.php" and set "daemon_password" to your daemon password.

Example:

          'daemon_db' => 'mysql:host=1.2.3.four;dbname=multicraft_daemon',     'daemon_db_user' => '*your MySQL user*',     'daemon_db_pass' => '*your MySQL password*',     'daemon_password' => '*strong daemon password*',        

Configuring MySQL

The above assumes that your MySQL server is already accepting remote connections. If this is not the case you take to configure MySQL to exercise and so.

Secure MySQL

A first step should always be to run "mysql_secure_installation":

mysql_secure_installation

Say "Y" to all questions (except for the first one if y'all don't want to alter the root countersign).

Alter the Heed Address

Edit your "my.cnf" and change the "bind-address" setting to your internet IP. If the setting does not exist y'all tin can create it in the "[mysqld]" department of that file. Make sure to remove any line that reads "skip-networking". For example, if the internet IP of your MySQL server is 1.2.3.4:

demark-address=1.ii.3.4 #skip-networking

And so restart MySQL:

service mysql restart

The service might be called differently on your system, for example "mysqld" instead of "mysql".

Grant Admission to Daemon MySQL Users

The post-obit queries are run directly in MySQL. You tin can use any tool to admission MySQL, from the control line information technology would be:

mysql -uroot -p

Supersede "root" with the proper noun of a privileged MySQL user.

Information technology'southward recommended to create a new MySQL user for each daemon. For example if your daemon is running on 2.3.4.5:

GRANT ALL ON multicraft_daemon.* TO daemon1@'two.iii.four.v' IDENTIFIED Past 'mysql_password_for_daemon1';

In the "multicraft.conf" of daemon ane you lot would then put:

database = mysql:host=i.2.3.4;dbname=multicraft_daemon dbUser = daemon1 dbPassword = mysql_password_for_daemon1

Information technology's too possible to use the same user for all daemons. In that case y'all'd supersede "TO daemon1@'2.three.4.5'" with "TO daemon@'%'" in the above example.

Yous can further restrict the database access of daemon users based on the following security recommendation: Split Daemon and Console Databases

Open Firewall / Router for MySQL

If y'all are backside a firewall or a router make certain that the MySQL server is accessible by the daemons. The default MySQL port is 3306. If you are using a different port you tin conform the "database" setting in your "multicraft.conf" accordingly, for example if the MySQL server is running on port 2345:

database = mysql:host=1.two.three.4;dbname=multicraft_daemon;port=2345

You tin test if MySQL has been configured correctly from the command line of the daemon motorcar:

mysql -h 1.ii.3.4 -u daemon1 -p multicraft_daemon

You should now be able to log in with the MySQL password you lot have fix for daemon 1 earlier.

Deject Installation / Mass Deployment

With the Dynamic license 1 Multicraft command panel can manage multiple Minecraft instances distributed over multiple physical or virtual machines.

To use Multicraft in such a configuration:

  • Multicraft has to be configured for remote functioning (meet Using MySQL above) with the same database configuration for all the daemons
  • Every daemon has to have a unique ID listed in its configuration file (setting "id" in your "multicraft.conf")

Once this is done each server tin dynamically exist assigned to one of the running daemons directly in the server settings. The daemons are automatically detected as shortly equally they are started trough an entry they create in the shared database.

Adding Region Logroller support

Multicraft comes with a feature that allows you to run an arbitraty world repair tool, for example "Region Logroller" (View on GitHub).
In club to configure Multicraft to use Region Fixer y'all can apply the post-obit instructions:

  • Download and excerpt Region Fixer to the "jar" directory of your daemon and brand sure information technology'south in a directory called "region-fixer". For example:
    cd /domicile/minecraft/multicraft/jar wget https://github.com/Fenixin/Minecraft-Region-Fixer/archive/master.zip unzip principal.zip mv Minecraft-Region-Logroller-master region-fixer
  • Download the repairtool.jar.conf and identify it in the "jar" directory likewise, make certain it's named "repairtool.jar.conf".
  • Enable the feature under "Settings"-"Panel Configuration": "Prove the repair tool push button for"

Changing the port of the standalone webserver (Windows)

If your port eighty (or 443 for HTTPS) is already in utilize by something else the installer will automatically ask you which port it should use.

Changing the port after the installation is possible as well. You can simply edit the file "Multicraft\config\httpd.conf" and alter the SRVPORT and/or SRVPORT_SSL settings at the top as needed.

Later completing these changes you need to restart the "Multicraft apache" service in the Windows Services panel.

How do I get FTP access to my server?

There is a YouTube video explaining this:
Multicraft Short: Give FTP access to a user

Accepting the Minecraft EULA

Minecraft versions later on 1.7.nine require you create a file called eula.txt that contains the line "eula=true" in your server directory.

For individual servers

If you merely want to accept the eula for your server it is sufficient to create this file or change the line to "eula=true" if it already exists. Y'all tin can apply your panel FTP file admission to achieve this.

For server providers

Users can employ their FTP admission to edit the eula.txt file as mentioned higher up. If you lot desire to facilitate accepting the EULA or fifty-fifty automate it in that location are several ways you can exercise that using Multicraft. Below you will observe a few examples.

Example 1 - Add a config file entry

You can configure the panel to treat the new eula.txt as a server configuration file and so users can change information technology without editing the file manually. Simply go to "Settings"->"Config File Settings" and click on "New Config File Setting". Fill in the fields like this:

Proper noun Minecraft EULA
Enabled True
File eula.txt
Options {"eula":{"proper name":"Accept Minecraft EULA","select":"bool"}}
Type Belongings File

Your users can then accept the EULA by going to "Files"->"Config Files"->"Minecraft EULA".

Example 2 - Add an "Accept EULA" button to the server settings (advanced)

On your console, add the following code to "protected/controllers/ServerController.php" later line 172:

          case 'accept_eula':                 if (Yii::app()->user->can($id, 'edit')                     && !McBridge::get()->serverCmd($id, 'run:builtin:script accept_eula')) {                     echo McBridge::become()->lastError();                 }                 break;        

Add together the post-obit lawmaking to "protected/views/server/view.php" later line 368:

          $attribs[] = array('label'=>Yii::t('mc', 'Minecraft EULA'), 'blazon'=>'raw',         'value'=>CHtml::ajaxButton(Yii::t('mc', 'Take EULA'), '', assortment(             'type'=>'POST',             'data'=>array('ajax'=>'accept_eula', Yii::app()->request->csrfTokenName=>Yii::app()->asking->csrfToken,),             'success'=>'function(e) {if (due east) alarm(e);}')));        

Then on the daemon, create or edit the file "scripts.conf" in your daemon directory (side by side to the multicraft.conf file) and add:

[accept_eula] command={BASE_DIR}/scripts/accept_eula.sh

and create a file called "accept_eula.sh" in the "scripts" directory that contains:

#!/bin/sh echo 'eula=true' > "$SERVER_DIR/eula.txt"

And brand sure it can be executed:

# chmod 755 scripts/accept_eula.sh

Please note that the script needs to use the Unix line catastrophe format so it's recommended to create it straight under Linux instead of creating it under Windows and uploading information technology.

Your users can now click this button to automatically create the eula.txt file.

Example 3 - Automatically create the file (avant-garde, Linux multiuser merely)

This is like to the suggestion above simply the script will exist run automatically every time a server starts. You lot need to brand sure your users are informed virtually the EULA and this acceptance.
To enable the script, but change the "userAgentPrepare" setting in your multicraft.conf to:

userAgentPrepare=scripts/accept_eula.sh

Make sure that there is no # in front of that line. After the change the daemon needs to be restarted for the change to have upshot.

The script can be created the same way every bit described in the previous signal:
Create a file chosen "accept_eula.sh" in the "scripts" directory that contains:

#!/bin/sh echo 'eula=true' > "$SERVER_DIR/eula.txt"

And make sure it can be executed:

# chmod 755 scripts/accept_eula.sh

Please note that the script needs to use the Unix line ending format and so information technology'south recommended to create information technology directly under Linux instead of creating information technology under Windows and uploading information technology.

This script will now run every time a server starts.

Limit Deejay Space / Quota Support (Linux merely, new in 2.0.0)

If y'all take already configured Quota support for your system you can enable the Multicraft quota feature past editing your multicraft.conf file and changing:

#enableQuota = fake

to

enableQuota = truthful

or past adding the setting to the [system] section if it does not exist still. The other "quota*" settings can be used to fine tune this feature.
The daemon has to exist restarted for the enableQuota setting modify to take effect.

Configure Linux Quota

If yous have not however enabled quota back up on your Linux organization you tin do so by post-obit these steps:

  1. Install the "quota" bundle, for case:
    apt-get install quota
    or
    yum install quota

  2. Edit the file /etc/fstab and add usrjquota=aquota.user,jqfmt=vfsv0 to the mount options of the filesystem where your servers will be located. For instance, alter:
    /dev/sda1 /dwelling house ext4 defaults 1 1
    to
    /dev/sda1 /home ext4 defaults,usrjquota=aquota.user,jqfmt=vfsv0 i i

  3. Remount the filesystem, create initial quota files, enable quota:
    mountain -o remount /dwelling quotacheck -avum quotaon -avu
    Replace /abode with the path to the filesystem y'all want to enable quota for.

Configure User Friendly URLs

You lot can configure the panel to show user friendly URLs, for instance:

http://example.com/server/1

instead of:

http://example.com/index.php?r=server/view&id=1

To attain this you tin edit the file protected/config/internal/application.php and look for the post-obit department:

          // uncomment the following to enable URLs in the format index.php/server/ane                                                              /*'urlFormat'=>'path',*/                                                                                                                // uncomment the following to hide the index.php function of the URL                                                                        /*'showScriptName'=>imitation,*/

Merely remove the "/*" and "*/" around the "urlFormat" and "showScriptName" settings to activate them. Notation that the apache rewrite module (mod_rewrite) is required for these settings to work correctly. Information technology'southward possible that these settings exercise non work correctly on your system and nosotros exercise not provide official support for enabling them.

Modify the Console Direction

The management of the console/server log is configurable under "Settings"->"Panel Configuration" using the setting "Bear witness console from bottom to pinnacle". The default setting is "No" (console goes from meridian to bottom).

Ship mails using SMTP instead of PHP post()

If you want to ship emails directly through an SMTP server instead of using the PHP mail() function you can edit the file protected/config/internal/awarding.php and look for the line:

'transportType'=>'smtp'

Remove the "/*" and "*/" effectually this cake of code and configure the values accordingly to use your SMTP server.

Daemon Callbacks

The daemon allows y'all to hook into and influence sure events. You lot can configure callback scripts for these events that go passed a JSON string with the callback arguments. The render value is expected to be JSON formated as well.
These callbacks tin be configured in the [advanced] section of the multicraft.conf file like this:

[advanced] callbackServerStart = /path/to/script.py callbackServerStop = /path/to/script.py callbackServerLogLine = /path/to/script.py callbackServerChatMsg = /path/to/script.py callbackServerPlayerConnected = /path/to/script.py callbackServerPlayerDisconnected = /path/to/script.py callbackServerGetResourceUsage = /path/to/script.py (2.4.0+) callbackServerCommand = /path/to/script.py (2.4.0+)

Parameters marked with a * are mutable, significant you tin can return them in the JSON response with a different value to override them.
The return value of the script has to be 0 on success and any other value on failure. Cancelable events will be canceled on failure.

Callback Parameters Cancelable
callbackServerStart id (int)
ip* (string)
port* (int)
players* (integer)
memory* (integer)
start_memory* (integer)
earth* (string)
working_directory* (string)
jarfile* (string)
template* (string)
setup* (string)
Yes
callbackServerStop id (int)
ip (string)
port (int)
players (integer)
memory (integer)
start_memory (integer, 2.four.0+)
globe (string)
working_directory (string)
jarfile (cord)
template (string, ii.iv.0+)
setup (cord, 2.4.0+)
country (string)
Yes
callbackServerLogLine id (int)
line* (string)
Yes
callbackServerChatMsg id (int)
time* (string)
sender* (string)
message* (cord)
Yes
callbackServerPlayerConnected id (int)
player_id* (int)
player_name* (string)
player_ip* (string)
player_banned* (cord)
player_level* (int)
No
callbackServerPlayerDisconnected id (int)
player_id* (int)
player_name* (string)
player_ip* (string)
player_banned* (string)
player_level* (int)
No
callbackServerGetResourceUsage id (int)
ip (string)
port (int)
players (integer)
memory (integer)
start_memory (integer)
globe (string)
working_directory (string)
jarfile (cord)
template (string)
setup (cord)
pid (int)
cpuUsage* (float)
memoryUsage* (float)
sysMemoryUsage* (float)
memoryRss* (float)
cpuCount* (int)
quotaUsage* (float)
No
callbackServerCommand id (int)
ip (cord)
port (int)
players (integer)
memory (integer)
start_memory (integer)
world (string)
working_directory (string)
jarfile (string)
template (string)
setup (string)
success* (bool)
success_string* (string)
response* (listing of strings/dicts)
No

Example for script argument and return value:

{"setup":"","ip":"1.2.3.4","start_memory":1024,"port":25565,"players":8,"working_directory":"","template":"","retention":1024,"world":"globe","id":1,"jarfile":"minecraft_server.jar"}

Windows Standalone: Update Coffee

  • If you already have the new version of Coffee installed yous can instruct Multicraft to use that java.exe instead of the one that comes with the installer. To do that you can edit the file "Multicraft\config\multicraft.conf" and alter the "java =" setting to bespeak to your Java installation, for example:
    coffee = C:\Program Files\Java\jdk-17.0.ane\bin\coffee.exe
  • Alternatively you can update the Java version shipped with the standalone package by downloading a new version from Adoptium.net. Make sure to download the nix packet, for example OpenJDK17U-jdk_x64_windows_hotspot_17.0.1_12.zip for Java 17. And so delete the contents of "Multicraft\vendor\java" and extract the contents of the "jdk-17.0.i+12" directory of the downloaded package into "Multicraft\vendor\java".

Different Java Versions

By default the .jar.conf files phone call Java through the {JAVA} variable in the "command" setting, e.yard.:

[offset] command = "{Coffee}" -Xmx{MAX_MEMORY}M -Xms{START_MEMORY}Thou -jar "{JAR}" nogui

This variable volition only be replaced by the "java" setting in your multicraft.conf file, by default:

java = /usr/bin/java

You can change this setting to the path of the "java" binary you'd similar to apply.

If the dissimilar server types yous offer require dissimilar Java versions information technology's no longer possible to use the same {Java} variable in all .jar.conf files. Instead y'all can apply the path to the correct version of Java directly in that "command" setting, e.k.:

[start] control = /usr/bin/java -Xmx{MAX_MEMORY}M -Xms{START_MEMORY}M -jar "{JAR}" nogui

That way you can ensure each JAR uses the correct Java version and for example continue {Java} for the version that is supported by most JARs or that is the current LTS release.

phillipssessood.blogspot.com

Source: https://www.multicraft.org/site/docs/howto

0 Response to "How to Upload a Custom Jar to Multicraft"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel