Skip to content

Binozoworks/InstantG-Client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

79 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

InstantMC Server

Publish Docker image

A standalone container running a minecraft server which is controllable through an http endpoint

Setup

docker pull ghcr.io/instantmc/client:latest
docker run -d --name mcclient -e auth='<YOUR_AUTH_KEY>' -p 25585:25585 ghcr.io/instantmc/client:latest
curl --header "auth: <YOUR_AUTH_KEY>" localhost:25585/server/start

Docker compose alternative:

services:
  mcserver:
    image: ghcr.io/instantmc/client:latest
    restart: always
    ports:
      - "25585:25585"
    environment:
      - auth=<YOUR_AUTH_KEY>
    volumes:
      - ~/minecraft-server-world/:/server/world/

HTTP Endpoints

Port: 25585

GET /

Returns the server status

Response:

{
    "server": {
        "running": false
    }
}

GET /server/start?blocking=true

Starts the Minecraft Server

  • blocking is optional. If true the response is sent when the minecraft server has fully booted up

Response:

{
  "message": "Minecraft Server has been started"
}

GET /server/stop?blocking=true

Stops the Minecraft Server

  • blocking is optional. If true the response is sent when the minecraft server has fully stopped

Response:

{
  "message": "Minecraft Server has stopped"
}

GET /server/player/op/{playername}

Grants operator permission to the target player

About

Controls the local Minecraft Server and is accessible through HTTP endpoints

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors