feat(caddy): support renaming configuration files

This commit is contained in:
2026-07-26 12:55:50 +07:00
parent f5a1f99dec
commit d5ea7b56cb
7 changed files with 350 additions and 27 deletions

22
scripts/dotnet-docker.sh Executable file
View File

@@ -0,0 +1,22 @@
#!/usr/bin/env bash
#
# Runs any dotnet command inside the official .NET SDK container, for machines
# without a local SDK installed. The repository is mounted at /src.
#
# Usage:
# ./scripts/dotnet-docker.sh test
# ./scripts/dotnet-docker.sh build CaddyManager.sln
# ./scripts/dotnet-docker.sh test --filter FullyQualifiedName~RenameCaddyConfiguration
#
# NuGet packages are cached in a named volume so only the first run downloads them.
set -euo pipefail
repo_root="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
exec docker run --rm \
--volume "$repo_root":/src \
--workdir /src \
--volume caddymanager-nuget:/root/.nuget/packages \
mcr.microsoft.com/dotnet/sdk:9.0 \
dotnet "$@"