Skip to content

Latest commit

 

History

History
61 lines (42 loc) · 2.9 KB

using-latest-daily.md

File metadata and controls

61 lines (42 loc) · 2.9 KB

Set up your machine to use the latest Aspire builds

These instructions will get you set up with the latest build of Aspire. If you just want the last preview release of .NET Aspire, the packages are on nuget.org, and install the latest Visual Studio 2022 version 17.9 Preview for the tooling.

Prepare the machine

See machine-requirements.md.

Add necessary NuGet feeds

The latest builds are pushed to a special feed, which you need to add:

dotnet nuget add source --name dotnet8 https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet8/nuget/v3/index.json

As usual this will add the feed to any existing NuGet.config in the directory or above, or else in the global NuGet.config. See configuring NuGet behavior to read more about that.

Alternatively, if you are using Visual Studio, you can Install and manage packages in Visual Studio and add the feed https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet8/nuget/v3/index.json there.

Install the .NET Aspire dotnet workload

First, we need to make sure you have the latest version of the workload manifest in your sdk. You can do this by running:

dotnet workload update --skip-sign-check --source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet8/nuget/v3/index.json
# If you are already on the latest version, then the command is a no-op.

Then, we are now able to install the workload with the version of the manifest that we just updated.

dotnet workload install aspire --skip-sign-check --source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet8/nuget/v3/index.json
# To update it later if you wish
# dotnet workload update --source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet8/nuget/v3/index.json

Now you are ready to create and run an Aspire app using these latest Aspire components.

Create a new Project

Create an empty .NET Aspire project on the command line:

dotnet new aspire
# Alternatively, to create a .NET Aspire project using the Starter template:
# dotnet new aspire-starter

These will create a .sln file and at least two projects.

Assuming the NuGet feed you added above is visible -- for example you added it globally or it's in a NuGet.config in this folder - you can now build that .sln

dotnet restore
dotnet build

And then run it (make sure that Docker desktop is started):

dotnet run --project "<directoryname>.AppHost"

Alternatively, if you are using Visual Studio, you can instead create a new Blazor Web App project and check the Enlist in Aspire orchestration box while creating it. Then use F5 to debug or Ctrl+F5 to launch without debugging.