Some checks are pending
CI / Integration (mcr.microsoft.com/mssql/server:2017-latest) (push) Blocked by required conditions
CI / Integration (mcr.microsoft.com/mssql/server:2019-latest) (push) Blocked by required conditions
CI / Integration (mcr.microsoft.com/mssql/server:2022-latest) (push) Blocked by required conditions
CI / Integration (mcr.microsoft.com/mssql/server:2025-latest) (push) Blocked by required conditions
CI / Build og unit tests (push) Successful in 1m10s
deploy hub / deploy (push) Successful in 19s
CI / MSI-installer (push) Successful in 50s
deploy-hub.yml builds deploy/hub/Dockerfile on the appserver runner, writes .env from repo secrets and starts docker-compose.prod.yml (external PostgreSQL, /data bind-mounted), then polls /health. ci.yml used runs-on: docker, which no runner has, so jobs never started. Build/tests and the MSI now run inside the SDK image via deploy/ci/Dockerfile, because the host-mode runner ignores container: and has no apt-get. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
24 lines
1 KiB
Docker
24 lines
1 KiB
Docker
# CI-byg til den self-hostede Forgejo runner (host-mode: jobs kører i runnerens
|
|
# egen Alpine-container, så 'container:' og apt-get virker ikke dér).
|
|
# Build og tests kører i stedet i SDK-imaget via docker build:
|
|
# docker build -f deploy/ci/Dockerfile --target test .
|
|
# docker buildx build -f deploy/ci/Dockerfile --target msi --build-arg VERSION=1.2.0 --output type=local,dest=dist .
|
|
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS test
|
|
ENV DOTNET_CLI_TELEMETRY_OPTOUT=1 DOTNET_NOLOGO=1
|
|
WORKDIR /src
|
|
COPY . .
|
|
RUN dotnet restore \
|
|
&& dotnet build --no-restore --configuration Release \
|
|
&& dotnet test --no-build --configuration Release --filter "Category!=Integration"
|
|
|
|
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS msi-build
|
|
ENV DOTNET_CLI_TELEMETRY_OPTOUT=1 DOTNET_NOLOGO=1
|
|
RUN apt-get update -q && apt-get install -y -q --no-install-recommends wixl msitools python3 \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
WORKDIR /src
|
|
COPY . .
|
|
ARG VERSION=1.0.0
|
|
RUN installer/build-msi.sh "$VERSION"
|
|
|
|
FROM scratch AS msi
|
|
COPY --from=msi-build /src/dist/ /
|