Implemented plugin referencing. Added healthcheck and custom base docker image
This commit is contained in:
6
Hosts/Moonlight.Api.Host/Api.props
Normal file
6
Hosts/Moonlight.Api.Host/Api.props
Normal file
@@ -0,0 +1,6 @@
|
||||
<Project>
|
||||
<ItemGroup>
|
||||
<!-- Put your plugin references here -->
|
||||
<!-- E.g. <PackageReference Include="MoonlightServers.Api" Version="2.1.0" /> -->
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
@@ -1,5 +1,5 @@
|
||||
# Base image
|
||||
FROM cgr.dev/chainguard/aspnet-runtime:latest AS base
|
||||
FROM git.battlestati.one/moonlight-panel/app_base:moonlight AS base
|
||||
WORKDIR /app
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
|
||||
@@ -29,6 +29,9 @@ COPY ["Moonlight.Shared/Moonlight.Shared.csproj", "Moonlight.Shared/"]
|
||||
COPY ["Hosts/Moonlight.Frontend.Host/Moonlight.Frontend.Host.csproj", "Hosts/Moonlight.Frontend.Host/"]
|
||||
COPY ["Hosts/Moonlight.Api.Host/Moonlight.Api.Host.csproj", "Hosts/Moonlight.Api.Host/"]
|
||||
|
||||
COPY ["Hosts/Moonlight.Frontend.Host/Frontend.props", "Hosts/Moonlight.Frontend.Host/"]
|
||||
COPY ["Hosts/Moonlight.Api.Host/Api.props", "Hosts/Moonlight.Api.Host/"]
|
||||
|
||||
RUN dotnet restore "Hosts/Moonlight.Api.Host/Moonlight.Api.Host.csproj"
|
||||
RUN dotnet restore "Hosts/Moonlight.Frontend.Host/Moonlight.Frontend.Host.csproj"
|
||||
|
||||
@@ -69,4 +72,6 @@ WORKDIR /app
|
||||
COPY --from=publish /app/publish-api .
|
||||
COPY --from=publish /app/publish-frontend/wwwroot ./wwwroot
|
||||
|
||||
HEALTHCHECK --interval=30s --timeout=3s --start-period=10s --retries=3 CMD ["/usr/bin/curl", "-sf", "-o", "/dev/null", "http://localhost:8080/"]
|
||||
|
||||
ENTRYPOINT ["dotnet", "Moonlight.Api.Host.dll"]
|
||||
@@ -29,4 +29,5 @@
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
|
||||
<Import Project="Api.props"/>
|
||||
</Project>
|
||||
|
||||
Reference in New Issue
Block a user