Server updates from the web panel with progress screen
- Updater checks git.mbm.wtf every 6 h (and on demand) for a newer <Version> on main, shows the new commits and the required mod version - Install: download the source, build it with dotnet publish into data/app/current, warn players and restart (exit code 75 for Docker/systemd, self-relaunch on Windows). At startup a newer installed update is loaded in its own AssemblyLoadContext; after 3 failed starts the built-in version runs - Panel: Update page, sidebar badge, full-screen progress overlay (download, build, install, restart) that survives the restart and reloads the panel - Panel sessions survive restarts (hashed tokens in data/panel_sessions.json) - Docker image is based on the .NET SDK so it can build updates - Version 2.9.0 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
+4
-2
@@ -8,13 +8,15 @@ WORKDIR /src
|
||||
COPY . .
|
||||
RUN dotnet publish -c Release -o /app
|
||||
|
||||
# aspnet: enthält Kestrel für das Web-Panel
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:10.0
|
||||
# sdk (enthält auch ASP.NET/Kestrel fürs Web-Panel): damit sich der Server im Panel selbst updaten kann
|
||||
# (lädt den Quellcode, baut ihn und legt ihn nach /data/app)
|
||||
FROM mcr.microsoft.com/dotnet/sdk:10.0
|
||||
WORKDIR /app
|
||||
COPY --from=build /app .
|
||||
ENV MSCO_DATA=/data
|
||||
# läuft als beliebige Benutzer-ID (docker compose "user:") - dann gibt es kein eigenes Home
|
||||
ENV HOME=/tmp
|
||||
ENV DOTNET_CLI_TELEMETRY_OPTOUT=1 DOTNET_NOLOGO=1
|
||||
# Befehle an den laufenden Server: docker exec msco-server msco players
|
||||
RUN printf '#!/bin/sh\nexec dotnet /app/MSCO.Server.dll --cmd "$@"\n' > /usr/local/bin/msco && chmod +x /usr/local/bin/msco
|
||||
VOLUME /data
|
||||
|
||||
Reference in New Issue
Block a user