Compare commits
2 Commits
8066478447
...
8669904edd
Author | SHA1 | Date | |
---|---|---|---|
8669904edd | |||
2f5212f8d0 |
@ -1,6 +1,6 @@
|
||||
# syntax=docker/dockerfile:1.7-labs
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/sdk:8.0-alpine AS build1
|
||||
FROM mcr.microsoft.com/dotnet/sdk:9.0-preview-alpine AS build1
|
||||
|
||||
WORKDIR /src
|
||||
COPY ./.config ./
|
||||
@ -10,7 +10,7 @@ WORKDIR Groceries
|
||||
COPY ./Groceries/libman.json ./
|
||||
RUN dotnet libman restore
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/sdk:8.0-alpine AS build2
|
||||
FROM mcr.microsoft.com/dotnet/sdk:9.0-preview-alpine AS build2
|
||||
|
||||
WORKDIR /src
|
||||
COPY ./Groceries.sln ./
|
||||
@ -23,7 +23,7 @@ COPY . ./
|
||||
COPY --from=build1 /src ./
|
||||
RUN dotnet publish --no-restore --output /out
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:8.0-alpine-composite AS base
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:9.0-preview-alpine-composite AS base
|
||||
WORKDIR /groceries
|
||||
|
||||
COPY --from=build2 /out .
|
||||
|
@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<WarningsAsErrors>nullable</WarningsAsErrors>
|
||||
|
@ -9,10 +9,12 @@
|
||||
<meta name="view-transition" content="same-origin" />
|
||||
<meta name="turbo-prefetch" content="false" />
|
||||
|
||||
<link rel="stylesheet" type="text/css" href="/css/main.css" asp-append-version="true" data-turbo-track="reload" />
|
||||
<link rel="stylesheet" type="text/css" href="@Assets["css/main.css"]" data-turbo-track="reload" />
|
||||
|
||||
<script type="module" src="/js/main.js" asp-append-version="true" data-turbo-track="reload"></script>
|
||||
<script type="module" src="/lib/hotwired/turbo/dist/turbo.es2017-esm.js"></script>
|
||||
<ImportMap />
|
||||
|
||||
<script type="module" src="@Assets["js/main.js"]" data-turbo-track="reload"></script>
|
||||
<script type="module" src="@Assets["lib/hotwired/turbo/dist/turbo.es2017-esm.js"]"></script>
|
||||
|
||||
<HeadOutlet />
|
||||
</head>
|
||||
|
@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<WarningsAsErrors>nullable</WarningsAsErrors>
|
||||
|
@ -51,11 +51,12 @@ builder.Services.AddDbContextPool<AppDbContext>(options => options
|
||||
|
||||
var app = builder.Build();
|
||||
|
||||
app.UseStaticFiles();
|
||||
app.UseRouting();
|
||||
app.UseSession();
|
||||
|
||||
app.MapControllers();
|
||||
app.MapStaticAssets();
|
||||
app.MapControllers()
|
||||
.WithStaticAssets();
|
||||
|
||||
await app.RunAsync();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user