Skip to content

Commit

Permalink
Implements #29
Browse files Browse the repository at this point in the history
  • Loading branch information
joergjo committed Nov 24, 2024
1 parent 19c6175 commit be28214
Show file tree
Hide file tree
Showing 9 changed files with 1,644 additions and 524 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Contoso Ads on Containers

## Introduction
This sample demonstrates how ASP.NET Core 8.0 can be used to build a cloud native application
This sample demonstrates how ASP.NET Core 9.0 can be used to build a cloud native application
that consists of a frontend web app and an API that communicate asynchronously via messaged
queues. Messaging between frontend and API is implemented using Dapr and both frontend and API
are hosted in Azure Container Apps.
Expand Down Expand Up @@ -38,9 +38,9 @@ This sample app uses a variety of technologies:
* [Azure Bicep](https://docs.microsoft.com/azure/azure-resource-manager/bicep/overview?tabs=**bicep**)
* [ASP.NET Core Razor Pages](https://learn.microsoft.com/en-us/aspnet/core/razor-pages/?view=aspnetcore-8.0&tabs=visual-studio-code)
* [ASP.NET Core Minimal API](https://learn.microsoft.com/en-us/aspnet/core/fundamentals/minimal-apis?view=aspnetcore-8.0)
* [Entity Framework Core 8.0](https://learn.microsoft.com/en-us/ef/core/)
* [Entity Framework Core 9.0](https://learn.microsoft.com/en-us/ef/core/)
* [Dapr](https://dapr.io)
* [C# 12](https://learn.microsoft.com/en-us/dotnet/csharp/whats-new/csharp-12)
* [C# 13](https://learn.microsoft.com/en-us/dotnet/csharp/whats-new/csharp-13)

## Prerequisites
You'll need a very small set of tools and skills to get started:
Expand Down
2 changes: 1 addition & 1 deletion docs/build-and-run.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Prerequisites

* macOS, Linux, or Windows 10/11 with the [Windows Subsystem for Linux](https://docs.microsoft.com/en-us/windows/wsl/) set up
* [.NET 8.0 SDK](https://dotnet.microsoft.com/en-us/download/dotnet/8.0)
* [.NET 9.0 SDK](https://dotnet.microsoft.com/en-us/download/dotnet/9.0)
* [Dapr](https://docs.dapr.io/getting-started/install-dapr-cli/)
* [Docker Desktop](https://docs.docker.com/docker-desktop/install/)

Expand Down
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "8.0.404",
"version": "9.0.100",
"rollForward": "latestFeature"
}
}
4 changes: 2 additions & 2 deletions src/ContosoAds.Web/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:8.0-alpine AS build
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:9.0-alpine AS build
ARG TARGETARCH
WORKDIR /source
COPY ["./ContosoAds.Web.csproj", "."]
RUN dotnet restore -a $TARGETARCH
COPY [".", "."]
RUN dotnet publish -a $TARGETARCH --no-restore -o /app /p:UseAppHost=false

FROM mcr.microsoft.com/dotnet/aspnet:8.0-alpine AS base
FROM mcr.microsoft.com/dotnet/aspnet:9.0-alpine AS base
EXPOSE 8080
ENV \
DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=false \
Expand Down
6 changes: 3 additions & 3 deletions src/ContosoAds.Web/Pages/About.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
Contoso Ads on Containers is a modernized version of the original <a href="https://docs.microsoft.com/en-us/azure/cloud-services/cloud-services-dotnet-get-started">Contoso Ads sample app for Azure Cloud Services</a>
and <a href="https://docs.microsoft.com/en-us/azure/app-service-web/websites-dotnet-webjobs-sdk-get-started">Azure WebJobs</a>.

The web application has been rebuilt with <a href="https://learn.microsoft.com/en-us/aspnet/core/razor-pages/?view=aspnetcore-8.0&tabs=visual-studio-code">ASP.NET Core Razor Pages 8.0</a>,
<a href="https://docs.microsoft.com/en-us/ef/core/">Entity Framework Core 8.0</a>, and <a href="https://dapr.io">Dapr</a> to run on <a href="https://azure.microsoft.com/en-us/services/container-apps/#overview">Azure Container Apps</a> .
The application is implemented in <a href="https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/">C# 12</a>.
The web application has been rebuilt with <a href="https://learn.microsoft.com/en-us/aspnet/core/razor-pages/?view=aspnetcore-9.0&tabs=visual-studio-code">ASP.NET Core Razor Pages 9.0</a>,
<a href="https://docs.microsoft.com/en-us/ef/core/">Entity Framework Core 9.0</a>, and <a href="https://dapr.io">Dapr</a> to run on <a href="https://azure.microsoft.com/en-us/services/container-apps/#overview">Azure Container Apps</a> .
The application is implemented in <a href="https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/">C# 13</a>.
</p>
<p>
This version uses <a href="https://docs.microsoft.com/en-us/azure/postgresql/flexible-server/">Azure Database for PostgreSQL Flexible Server</a> and
Expand Down
Loading

0 comments on commit be28214

Please sign in to comment.