refracta / dcss-server

Containerized DCSS Server
https://crawl.nemelex.cards
2 stars 0 forks source link

dcss-server

README.md was created based on README.ko.md, which was automatically translated via ChatGPT.

This script is designed to simplify the deployment and management of a Dungeon Crawl Stone Soup server. It includes as many fork versions as possible (DCSS CA, HellCrawl, GnollCrawl, BloatCrawl2, GoonCrawl, X-Crawl, StoatSoup, BcadrenCrawl, KimchiCrawl, AddedCrawl) and official release versions (0.11 ~ 0.31) in a latest Ubuntu image environment.

First Run Guide:

Prerequisites

One-Line Deploy

curl -fsSL https://raw.githubusercontent.com/refracta/dcss-server/stable/server/scripts/deploy/stable.sh | sudo -E sh -
develop ```bash curl -fsSL https://raw.githubusercontent.com/refracta/dcss-server/develop/server/scripts/deploy/develop.sh | sudo -E sh - ```

Fast Deploy

git clone https://github.com/refracta/dcss-server -b stable
cd dcss-server/server
docker compose -f docker-compose.yml -f docker-compose.stable.yml config > docker-compose.combine.yml && \
mv docker-compose.combine.yml docker-compose.yml

# Update with the latest settings (use if you want to update)
docker compose run --rm -e CMD='cd $DGL_CONF_HOME && git pull' dcss-server
# Download pre-built game binaries and settings
docker compose run --rm -e CMD='$SCRIPTS/utils/release.sh download -o -p /data -n stable-game-data' dcss-server
# Run with random ports
docker compose up -d && docker compose logs -f
# Run with specified ports
docker compose -f docker-compose.yml -f docker-compose.ports.yml up -d && docker compose logs -f
develop ```bash git clone https://github.com/refracta/dcss-server -b develop cd dcss-server/server docker compose run --rm -e CMD='cd $DGL_CONF_HOME && git pull' dcss-server docker compose run --rm -e CMD='$SCRIPTS/utils/release.sh download -o -p /data -n game-data' dcss-server # Run with random ports docker compose up -d && docker compose logs -f # Run with specified ports docker compose -f docker-compose.yml -f docker-compose.ports.yml up -d && docker compose logs -f ```

Deploy with Build

git clone https://github.com/refracta/dcss-server -b stable
cd dcss-server/server
docker compose -f docker-compose.yml -f docker-compose.ports.yml -f docker-compose.stable.yml config > docker-compose.combine.yml && \
mv docker-compose.combine.yml docker-compose.yml

# If you need to build without downloading the image stored in Docker Hub, you can use the following command.
docker compose build

# This command can be used optionally to download ccache files to speed up compilation.
# Without it, the full build takes over 6 hours on the ubuntu-24.04 image of the GitHub Action Runner, but with it, it accelerates to about 45 minutes.
docker compose run --rm -e CMD='$SCRIPTS/utils/release.sh download -p /data/ccache -n stable-ccache' dcss-server

# USE_DWEM: apply the https://github.com/refracta/dcss-webtiles-extension-module.
# USE_REVERSE_PROXY: Apply patches to record X-Forwarded-For IPs in logs.
# CMD: Can be used to run scripts inside the container.
# "$SCRIPTS/game/install-crawl-versions.sh"=build all crawl versions, "$SCRIPTS/game/install-trunk.sh"=build only the trunk version, ""=run the server without building. (If pre-built data exists)
docker compose run --rm -e CMD='$SCRIPTS/game/install-crawl-versions.sh' dcss-server
USE_DWEM=true USE_REVERSE_PROXY=true docker compose up -d && docker compose logs -f
develop ```bash git clone https://github.com/refracta/dcss-server -b develop cd dcss-server/server docker compose -f docker-compose.yml -f docker-compose.ports.yml config > docker-compose.combine.yml && \ mv docker-compose.combine.yml docker-compose.yml docker compose build docker compose run --rm -e CMD='$SCRIPTS/utils/release.sh download -p /data/ccache -n ccache' dcss-server docker compose run --rm -e CMD='$SCRIPTS/game/install-crawl-versions.sh' dcss-server USE_DWEM=true USE_REVERSE_PROXY=true docker compose up -d && docker compose logs -f ```

Notes

Repository Management

Upstream Projects

Thanks to

With the help of many developers in the #crawl-dev IRC channel, the implementation goals of this project were successfully achieved. Special thanks to gammafunk for their assistance with server settings, and Sentei, the developer of DCSSReplay and maintainer of dgamelaunch-dcss-forks-server, for monitoring the server setup process and providing invaluable advice and issue resolution.