docs: clarify new default behavior with interactive console and colorized logs (#2632)

This commit is contained in:
Geoff Bourne 2024-02-04 15:47:13 -06:00 committed by GitHub
parent 8222a79bf4
commit c424dc0c47
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -41,21 +41,9 @@ See [Custom worlds directory path](../misc/world-data.md#custom-worlds-directory
## Interactive and Color Console
If you would like to `docker attach` to the Minecraft server console with color and interactive capabilities, then add
When RCON is enabled, which is the default, and [TTY](https://docs.docker.com/compose/compose-file/05-services/#tty) is enabled on the container, then some server types will output colorized logs and provide a fully interactive console. To access the interactive console, use [`docker attach`](https://docs.docker.com/engine/reference/commandline/container_attach/) (not `exec`). When finished, make sure to use the sequence Control-P, Control-Q to detach without stopping the container.
```
-e EXEC_DIRECTLY=true
```
> **NOTES**
>
> This feature doesn't work via rcon, so you will need to `docker attach` to the container. Use the sequence Ctrl-P, Ctrl-Q to detach.
>
> This will bypass graceful server shutdown handling when using `docker stop`, so be sure the server console's `stop` command.
>
> Make to enable stdin and tty with `-it` when using `docker run` or `stdin_open: true` and `tty: true` when using docker compose.
>
> This feature is incompatible with Autopause and cannot be set when `ENABLE_AUTOPAUSE=true`.
If this behavior interferes with the log content, then disable TTY or remove the setting entirely since the default is disabled. In a compose file, set the service's `tty` parameter to `false`. On the `docker run` command-line remove the `-t` argument.
## Server Shutdown Options