Giter VIP home page Giter VIP logo

minecraftd's Introduction

minecraftd

Minecraftd is a wrapper script and systemd unit to host a minecraft server.

Minecraftd can start a minecraft server in the background via systemd or directly from the command line. A simple fifo is created to allow sending commands directly to the server's stdin.

Minecraftd can be run by any user that has write access to the minecraft server directory. The systemd unit is configured to run minecraftd as user minecraft.

Installation

make install

Installation does not create a minecraft server directory. You must create a server directory and/or congfigure minecraftd to use that directory after installation.

Note that installation is not explicitly required to run the minecraftd script. You may create a minecraftd.conf in any directory and run minecraftd there to source it and start a minecraft server.

Minecraftd is also available in the AUR.

Dependencies

Usage

minecraftd [COMMAND]

Commands

start : Start minecraft server.

stop : Stop minecraft server.

command [COMMAND...] : Send COMMAND to minecraft server stdin.

connect : Launch interactive minecraft server stdin prompt.

-H, --help : Display help and exit.

Usage: systemd

systemctl enable minecraftd.service
systemctl start minecraftd.service

Configuration

Minecraftd sources the following config files (if they exist) in order:

  • /etc/minecraftd.conf
  • /etc/minecraftd.d/*
  • ~/.config/minecraftd.conf
  • ./minecraftd.conf

These files are strictyaml containing the following keys:

jar : Minecraft server jar file. (default: /usr/share/java/minecraft-server.jar)

mem : Maximum memory allocated to minecraft server. (default: 2G)

srv : Minecraft server directory. (default: /srv/minecraft)

Why?

This doesn't require tmux or screen as some other minecraft server control scripts do. Don't get me wrong, I love tmux, but I'd rather not have systemd running tmux running a server when I could just have systemd run a server.


Chris Magyar
MIT

minecraftd's People

Contributors

arcmags avatar

Stargazers

 avatar

Watchers

 avatar  avatar

minecraftd's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.