-
Notifications
You must be signed in to change notification settings - Fork 83
User/saweb/listen for kestrel events #55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
e2987bd
df9e28c
c35295c
cee7381
e6b4058
8e9eaad
ea9ba91
a1b5ca9
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
**/.classpath | ||
**/.dockerignore | ||
**/.env | ||
**/.git | ||
**/.gitignore | ||
**/.project | ||
**/.settings | ||
**/.toolstarget | ||
**/.vs | ||
**/.vscode | ||
**/*.*proj.user | ||
**/*.dbmdl | ||
**/*.jfm | ||
**/azds.yaml | ||
**/bin | ||
**/charts | ||
**/docker-compose* | ||
**/Dockerfile* | ||
**/node_modules | ||
**/npm-debug.log | ||
**/obj | ||
**/secrets.dev.yaml | ||
**/values.dev.yaml | ||
LICENSE | ||
README.md | ||
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,13 +2,16 @@ | |
<PropertyGroup> | ||
<TargetFramework>net5.0</TargetFramework> | ||
<LangVersion>8</LangVersion> | ||
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS> | ||
<DockerfileContext>..\..</DockerfileContext> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Neat, was not aware of these properties! |
||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\..\src\prometheus-net.DotNetRuntime\prometheus-net.DotNetRuntime.csproj" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="Microsoft.VisualStudio.Azure.Containers.Tools.Targets" Version="1.10.13" /> | ||
<PackageReference Include="prometheus-net.AspNetCore" Version="4.0.0" /> | ||
<PackageReference Include="prometheus-net" Version="4.1.1" /> | ||
</ItemGroup> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,22 @@ | ||
#FROM mcr.microsoft.com/dotnet/core/sdk:3.1.406 AS build | ||
#See https://aka.ms/containerfastmode to understand how Visual Studio uses this Dockerfile to build your images for faster debugging. | ||
|
||
FROM mcr.microsoft.com/dotnet/aspnet:5.0 AS base | ||
WORKDIR /app | ||
EXPOSE 80 | ||
|
||
FROM mcr.microsoft.com/dotnet/sdk:5.0 AS build | ||
WORKDIR /src | ||
COPY ["examples/AspNetCoreExample/AspNetCoreExample.csproj", "examples/AspNetCoreExample/"] | ||
COPY ["src/prometheus-net.DotNetRuntime/prometheus-net.DotNetRuntime.csproj", "src/prometheus-net.DotNetRuntime/"] | ||
RUN dotnet restore "examples/AspNetCoreExample/AspNetCoreExample.csproj" | ||
COPY . . | ||
RUN dotnet publish "examples/AspNetCoreExample" -c Release -o /app | ||
WORKDIR "/src/examples/AspNetCoreExample" | ||
RUN dotnet build "AspNetCoreExample.csproj" -c Release -o /app/build | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There should be no need for an explicit |
||
|
||
FROM build AS publish | ||
RUN dotnet publish "AspNetCoreExample.csproj" -c Release -o /app/publish | ||
|
||
#FROM mcr.microsoft.com/dotnet/core/aspnet:3.1.3 AS final | ||
#FROM mcr.microsoft.com/dotnet/core/aspnet:3.1.10 AS final | ||
FROM mcr.microsoft.com/dotnet/aspnet:5.0 as final | ||
FROM base AS final | ||
WORKDIR /app | ||
COPY --from=build /app /app | ||
ENTRYPOINT ["dotnet", "AspNetCoreExample.dll"] | ||
COPY --from=publish /app/publish . | ||
ENTRYPOINT ["dotnet", "AspNetCoreExample.dll"] |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# FROM mcr.microsoft.com/dotnet/core/sdk:3.1.201 AS build | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We should delete this if it's no longer in use. I haven't yet checked out your branch but I still do want to support building the docker image via |
||
#FROM mcr.microsoft.com/dotnet/core/sdk:3.1.406 AS build | ||
FROM mcr.microsoft.com/dotnet/sdk:5.0 AS build | ||
WORKDIR /src | ||
COPY . . | ||
RUN dotnet publish "examples/AspNetCoreExample" -c Release -o /app | ||
|
||
#FROM mcr.microsoft.com/dotnet/core/aspnet:3.1.3 AS final | ||
#FROM mcr.microsoft.com/dotnet/core/aspnet:3.1.10 AS final | ||
FROM mcr.microsoft.com/dotnet/aspnet:5.0 as final | ||
WORKDIR /app | ||
COPY --from=build /app /app | ||
ENTRYPOINT ["dotnet", "AspNetCoreExample.dll"] |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,22 @@ | ||
{ | ||
{ | ||
"$schema": "http://json.schemastore.org/launchsettings.json", | ||
"profiles": { | ||
"AspNetCoreExample": { | ||
"commandName": "Project", | ||
"launchBrowser": true, | ||
"launchUrl": "metrics", | ||
"applicationUrl": "http://localhost:5000", | ||
"environmentVariables": { | ||
"ASPNETCORE_ENVIRONMENT": "Development", | ||
"Example__UseDefaultMetrics": "true", | ||
"Example__UseDebuggingMetrics": "true", | ||
"Example__UseDefaultMetrics": "true" | ||
} | ||
"ASPNETCORE_ENVIRONMENT": "Development" | ||
}, | ||
"applicationUrl": "http://localhost:5000" | ||
}, | ||
"Docker": { | ||
"commandName": "Docker", | ||
"launchBrowser": true, | ||
"launchUrl": "{Scheme}://{ServiceHost}:{ServicePort}/metrics", | ||
"publishAllPorts": true | ||
} | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, thanks!