-
Notifications
You must be signed in to change notification settings - Fork 523
feat: replace docker compose with dotnet aspire #223
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
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
1a464fa
feat(app): initialize application with PostgreSQL and update launch s…
kamilbaczek 4501213
feat: update project file and program configuration for PostgreSQL in…
kamilbaczek 9bd72e7
feat: update SonarAnalyzer.CSharp to version 10.15.0 across project f…
kamilbaczek 0a29e72
feat: update migration files and change Program.cs to use async run
kamilbaczek 27e5b89
feat: upgrade postgres
kamilbaczek cf800ef
docs: update documentation of aspire
kamilbaczek 5b4d683
feat: add .NET Aspire link to README
kamilbaczek ab7af95
Update Chapter-1-initial-architecture/README.adoc
kamilbaczek 12c91a2
Update Chapter-1-initial-architecture/Src/Fitnet.AppHost/Fitnet.AppHo…
kamilbaczek File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
22 changes: 22 additions & 0 deletions
22
Chapter-1-initial-architecture/Src/Fitnet.AppHost/Fitnet.AppHost.csproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| <Project Sdk="Microsoft.NET.Sdk"> | ||
| <Sdk Name="Aspire.AppHost.Sdk" Version="9.0.0"/> | ||
|
|
||
| <PropertyGroup> | ||
| <OutputType>Exe</OutputType> | ||
| <ImplicitUsings>enable</ImplicitUsings> | ||
| <Nullable>enable</Nullable> | ||
| <IsAspireHost>true</IsAspireHost> | ||
| <UserSecretsId>b4ef32d8-9e82-4dd1-b9a7-bc43e2c564e9</UserSecretsId> | ||
| </PropertyGroup> | ||
|
|
||
| <ItemGroup> | ||
| <PackageReference Include="Aspire.Hosting.AppHost" Version="9.0.0"/> | ||
| <PackageReference Include="Aspire.Hosting.PostgreSQL" Version="9.0.0"/> | ||
| <PackageReference Update="SonarAnalyzer.CSharp" Version="10.15.0.120848" /> | ||
| </ItemGroup> | ||
|
|
||
| <ItemGroup> | ||
| <ProjectReference Include="..\Fitnet\Fitnet.csproj"/> | ||
| </ItemGroup> | ||
|
|
||
| </Project> | ||
17 changes: 17 additions & 0 deletions
17
Chapter-1-initial-architecture/Src/Fitnet.AppHost/Program.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| using Projects; | ||
|
|
||
| var builder = DistributedApplication.CreateBuilder(args); | ||
| var postgres = builder.AddPostgres("postgres") | ||
| .WithImage("postgres", "15.15") | ||
|
kamilbaczek marked this conversation as resolved.
|
||
| .WithPgAdmin(); | ||
|
|
||
| var fitnetDatabase = postgres.AddDatabase("fitnetsdb", "fitnet"); | ||
|
kamilbaczek marked this conversation as resolved.
|
||
| builder.AddProject<Fitnet>("fitnet") | ||
| .WithEnvironment("ASPNETCORE_ENVIRONMENT", "Development") | ||
| .WithReference(fitnetDatabase, "Passes") | ||
| .WithReference(fitnetDatabase, "Contracts") | ||
| .WithReference(fitnetDatabase, "Reports") | ||
| .WithReference(fitnetDatabase, "Offers") | ||
| .WaitFor(postgres); | ||
|
|
||
| await builder.Build().RunAsync(); | ||
17 changes: 17 additions & 0 deletions
17
Chapter-1-initial-architecture/Src/Fitnet.AppHost/Properties/launchSettings.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| { | ||
| "$schema": "https://json.schemastore.org/launchsettings.json", | ||
| "profiles": { | ||
| "https": { | ||
| "commandName": "Project", | ||
| "dotnetRunMessages": true, | ||
| "launchBrowser": true, | ||
| "applicationUrl": "https://localhost:17105;http://localhost:15107", | ||
| "environmentVariables": { | ||
| "ASPNETCORE_ENVIRONMENT": "Development", | ||
| "DOTNET_ENVIRONMENT": "Development", | ||
| "DOTNET_DASHBOARD_OTLP_ENDPOINT_URL": "https://localhost:21129", | ||
| "DOTNET_RESOURCE_SERVICE_ENDPOINT_URL": "https://localhost:22189" | ||
| } | ||
| } | ||
| } | ||
| } |
9 changes: 9 additions & 0 deletions
9
Chapter-1-initial-architecture/Src/Fitnet.AppHost/appsettings.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| { | ||
| "Logging": { | ||
| "LogLevel": { | ||
| "Default": "Information", | ||
| "Microsoft.AspNetCore": "Warning", | ||
| "Aspire.Hosting.Dcp": "Warning" | ||
| } | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,7 @@ | ||
| <Solution> | ||
| <Project Path="Fitnet.ArchitectureTests\Fitnet.ArchitectureTests.csproj" Type="Classic C#" /> | ||
| <Project Path="Fitnet.IntegrationTests\Fitnet.IntegrationTests.csproj" Type="Classic C#" /> | ||
| <Project Path="Fitnet.UnitTests\Fitnet.UnitTests.csproj" Type="Classic C#" /> | ||
| <Project Path="Fitnet\Fitnet.csproj" Type="Classic C#" /> | ||
| <Project Path="Fitnet.AppHost/Fitnet.AppHost.csproj" /> | ||
| <Project Path="Fitnet.ArchitectureTests\Fitnet.ArchitectureTests.csproj" Type="C#" /> | ||
| <Project Path="Fitnet.IntegrationTests\Fitnet.IntegrationTests.csproj" Type="C#" /> | ||
| <Project Path="Fitnet.UnitTests\Fitnet.UnitTests.csproj" Type="C#" /> | ||
| <Project Path="Fitnet\Fitnet.csproj" Type="C#" /> | ||
|
kamilbaczek marked this conversation as resolved.
|
||
| </Solution> | ||
This file was deleted.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
...Fitnet/Contracts/Data/Database/Migrations/20230608060456_MakeSignedAtColumnNotRequired.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
.../Contracts/Data/Database/Migrations/20230608060545_AddCustomerIdColumntoContractsTable.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
...Data/Database/Migrations/20230618131127_ContractsAddColumnsToSupportContractExpiration.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
...itecture/Src/Fitnet/Offers/Data/Database/Migrations/20230503180337_Create_Offers_table.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
...chitecture/Src/Fitnet/Passes/Data/Database/Migrations/20230503180338_CreatePassesTable.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.