Skip to content

Latest commit

 

History

History
154 lines (113 loc) · 4.45 KB

docker-runtime-host.md

File metadata and controls

154 lines (113 loc) · 4.45 KB

Run Docker-Backed Servers From Host AlphaGSM

This guide is the primary direct-host path after the Docker-first migration.

For agent-operated setup, follow the installation/request policy. Ask to install an absent game for a vague run request; clarify unspecified intent if that game already exists. Docker use and repository runtime image pulls/builds need no extra approval. Ask before installing new external host software, including missing Docker/Compose or host game runtimes. Prefer the containerized manager when it supplies setup tools.

Use it when you want AlphaGSM itself to run on the machine normally, but you want individual game servers to run as Docker containers instead of screen-backed host processes.

This is not the same as Run AlphaGSM In Docker, where the whole AlphaGSM manager runs inside a container.

The documented runtime-validation baseline for this path is Ubuntu 24.04 or a newer Linux host.

What This Mode Does

With [runtime] backend = docker, AlphaGSM still handles the normal server lifecycle:

  • create
  • setup
  • start
  • status
  • query
  • info
  • stop

The difference is that start launches a Docker container for modules that expose Docker runtime metadata.

What You Need

You need:

  • a normal host install of AlphaGSM
  • a working host Docker CLI and daemon
  • permission to run docker as your user
  • a game module that supports the Docker runtime hooks

AlphaGSM can still use the normal process runtime for modules that are not set up for Docker, but that process path is the fallback rather than the preferred user-facing workflow.

1. Configure The Runtime Backend

Copy the config if you have not done that yet:

cp alphagsm.conf-template alphagsm.conf

Then set the runtime backend:

[runtime]
backend = docker

AlphaGSM resolves the effective runtime per server. If the module exposes Docker metadata, AlphaGSM will store the resolved runtime fields in that server's JSON datastore during create / setup.

2. Create And Set Up A Server

Example with Minecraft Vanilla:

./alphagsm mymc create minecraft.vanilla
./alphagsm mymc setup

Keep the install path on a normal host-visible path such as:

/srv/alphagsm/servers/mymc

For a direct host install, there is no same-path manager-container requirement. The main rule is that the host Docker daemon must be able to bind-mount the path you choose.

3. Check The Runtime Before Start

Use the built-in doctor command:

./alphagsm mymc doctor

This prints the effective runtime decision and, for Docker-backed servers, includes:

  • configured backend
  • module runtime preference
  • resolved runtime family
  • image and container name
  • Docker CLI health
  • local image presence
  • current container state

If Docker is configured but the module still resolves to process, the doctor output will show that clearly.

4. Start And Check The Server

./alphagsm mymc start
./alphagsm mymc status
./alphagsm mymc query
./alphagsm mymc info

5. Stop It Later

./alphagsm mymc stop

Steam-owned files

Log in on the host before setup. SteamCMD runs in the AlphaGSM process, whether that process is the alphagsm command, a standalone binary, or a Python library call that later starts a Docker game server:

./alphagsm steam-auth login owned your_steam_username
./alphagsm myserver setup --auth-profile owned

The profile stays under [core] alphagsm_path on a Linux filesystem. AlphaGSM refuses to mount that steam-auth/ directory, a parent that contains it, or a path inside it into the game container. The refusal happens before docker run. Anonymous SteamCMD SDK libraries outside the profile can still be mounted. Keep the server install directory outside steam-auth/. A login without a terminal is rejected. See SteamCMD session profiles.

Notes

  • AlphaGSM uses the runtime-family image declared by the module or the shared family defaults in src/server/runtime.py.
  • If a default AlphaGSM runtime-family image tag is missing locally, AlphaGSM can build the matching in-repo Dockerfile on demand.
  • Docker-backed servers still keep their AlphaGSM metadata under the normal server datastore path.
  • doctor is the fastest way to tell whether a server is actually resolving to Docker, which family/image it will use, and whether the local host can launch it cleanly.