platformplatform / PlatformPlatform

🚀 Pre-alpha state. A platform designed for building enterprise-grade, multi-tenant products using Azure, .NET, React, TypeScript, Infrastructure as Code, etc.
https://platformplatform.github.io
MIT License
226 stars 24 forks source link

Prepare PlatformPlatform solutions for multiple self-contained systems #457

Closed tjementum closed 3 months ago

tjementum commented 3 months ago

Summary & Motivation

Refactor the PlatformPlatform solutions to prepare for multiple self-contained systems. When using Aspire AppHost, each project name needs to be unique, so all Account Management and Shared Kernel system projects have been renamed from generic names like Api to AccountManagement.Api.

Additionally, the API endpoints have been changed from, e.g., /api/* to /api/account-management/*. This has been updated in the YARP reverse proxy. To ensure that the SPA is still served from the root, a new separate YARP route called account-management-spa has been created.

The custom Client Filesystem Router has been updated to allow for a basename (base path) like /back-office, ensuring that it’s possible to host multiple SPAs from different self-contained systems. The HTML title has been updated to include the name of the self-contained system, making it easy to verify when switching from one system to another.

The AccountManagement.sln and SharedKernel.sln have been replaces with new Solution Filter files (.slnf) in the root of the /application directory. This makes it easier to open and work with one self-contained system in isolation. Additionally, the large PlatformPlatform.sln solution file has been reorganized so that projects appear in a logical order, ensuring that dependent projects are imported after their dependencies. Also, the SolutionGuid has been removed, as this must be unique when cloning the template, and it’s better to not have an ID than to have the same ID in two solutions.

The Docker Volume for the SQL and Blob storage has been prefixed with platform-platform, allowing multiple PlatformPlatform instances (with different names) to run side by side, e.g., renaming the PlatformPlatform.sln to YourSaaSProduct.sln.

The Developer CLI has been updated to dynamically look up the solution file name, ensuring it’s easy to rename the PlatformPlatform.sln to something different without having to update the CLI.

Checklist

sonarcloud[bot] commented 3 months ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud