Skip to content

Commit e2d4e54

Browse files
Copilotjongalloway
andcommitted
Add .NET 9 setup configuration and fix Aspire compatibility
Co-authored-by: jongalloway <[email protected]>
1 parent e439e46 commit e2d4e54

File tree

3 files changed

+25
-3
lines changed

3 files changed

+25
-3
lines changed

copilot-setup-steps.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Setup .NET 9 Environment
2+
description: Install .NET 9 SDK and required workloads for NLWebNet development
3+
steps:
4+
- name: Install .NET 9 SDK
5+
run: |
6+
# Download and install .NET 9 SDK
7+
curl -sSL https://dot.net/v1/dotnet-install.sh | bash /dev/stdin --version latest --channel 9.0
8+
9+
# Add .NET to PATH for current session
10+
export DOTNET_ROOT=$HOME/.dotnet
11+
export PATH=$PATH:$DOTNET_ROOT:$DOTNET_ROOT/tools
12+
13+
# Verify installation
14+
$HOME/.dotnet/dotnet --version
15+
16+
# Set environment variables for subsequent steps
17+
echo "DOTNET_ROOT=$HOME/.dotnet" >> $GITHUB_ENV
18+
echo "$HOME/.dotnet" >> $GITHUB_PATH
19+
echo "$HOME/.dotnet/tools" >> $GITHUB_PATH
20+
21+
# Install required workloads
22+
$HOME/.dotnet/dotnet workload install aspire

samples/AspireHost/AspireHostingExtensions.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ public static IResourceBuilder<ProjectResource> AddNLWebNetAppWithDataBackend(
5454
IResourceBuilder<IResourceWithConnectionString> dataBackend)
5555
{
5656
return builder.AddNLWebNetApp(name)
57-
.WithReference(dataBackend)
58-
.WithEnvironment("NLWebNet__DataBackend__ConnectionString", dataBackend.Resource.GetConnectionString());
57+
.WithReference(dataBackend);
5958
}
6059
}

samples/AspireHost/NLWebNet.AspireHost.csproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<Project Sdk="Microsoft.NET.Sdk">
2+
<Sdk Name="Aspire.AppHost.Sdk" Version="9.0.0" />
23

34
<PropertyGroup>
45
<OutputType>Exe</OutputType>
@@ -18,7 +19,7 @@
1819
</ItemGroup>
1920

2021
<ItemGroup>
21-
<ProjectReference Include="..\..\src\NLWebNet\NLWebNet.csproj" />
22+
<ProjectReference Include="..\..\src\NLWebNet\NLWebNet.csproj" IsAspireProjectResource="false" />
2223
<ProjectReference Include="..\..\demo\NLWebNet.Demo.csproj" />
2324
</ItemGroup>
2425

0 commit comments

Comments
 (0)