All checks were successful
Caddy Manager CI build / docker (push) Successful in 6m37s
Preserve configuration defaults with the .NET 10 binder and update dependencies, Docker builds, CI, and test tooling.
23 lines
716 B
Bash
Executable File
23 lines
716 B
Bash
Executable File
#!/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:10.0 \
|
|
dotnet "$@"
|