diff --git a/src/Nocr.TextMatcher.Host/Dockerfile b/src/Nocr.TextMatcher.Host/Dockerfile index ec01d1d..5612290 100644 --- a/src/Nocr.TextMatcher.Host/Dockerfile +++ b/src/Nocr.TextMatcher.Host/Dockerfile @@ -1,5 +1,6 @@ FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base WORKDIR /app +RUN apt-get update && apt-get install -y curl && rm -rf /var/lib/apt/lists/* EXPOSE 80 EXPOSE 443 diff --git a/src/Nocr.TextMatcher.Host/Infrastructure/Startup.cs b/src/Nocr.TextMatcher.Host/Infrastructure/Startup.cs index 9394bc8..abb7d6b 100644 --- a/src/Nocr.TextMatcher.Host/Infrastructure/Startup.cs +++ b/src/Nocr.TextMatcher.Host/Infrastructure/Startup.cs @@ -30,6 +30,8 @@ public class Startup services.AddAppServices(); services.AddEfPersistence(Configuration.GetConnectionString(nameof(TextMatcherContext))!); + + services.AddHealthChecks(); services.Configure(Configuration.GetSection(nameof(RebusRabbitMqOptions))); services.AddRebus((builder, ctx) => @@ -54,6 +56,7 @@ public class Startup } app.UseRouting(); + app.UseHealthChecks("/health"); app.UseEndpoints(builder => builder.MapControllers()); var rabbitMqOptions = app.ApplicationServices.GetRequiredService>(); diff --git a/src/Nocr.TextMatcher.Migrator/Nocr.TextMatcher.Migrator.csproj b/src/Nocr.TextMatcher.Migrator/Nocr.TextMatcher.Migrator.csproj index 2f6af26..9aab213 100644 --- a/src/Nocr.TextMatcher.Migrator/Nocr.TextMatcher.Migrator.csproj +++ b/src/Nocr.TextMatcher.Migrator/Nocr.TextMatcher.Migrator.csproj @@ -25,9 +25,10 @@ .dockerignore - - Always - + + PreserveNewest + PreserveNewest +