run-aspnetcore-microservices icon indicating copy to clipboard operation
run-aspnetcore-microservices copied to clipboard

Microservices on .Net platforms which used ASP.NET Web API, Docker, RabbitMQ, MassTransit, Grpc, Yarp API Gateway, PostgreSQL, Redis, SQLite, SqlServer, Marten, Entity Framework Core, CQRS, MediatR, D...

Results 45 run-aspnetcore-microservices issues
Sort by recently updated
recently updated
newest added

I suggest removing the "event-sourcing" tag from the project as it does not exemplify this. The persistence mechanism present in the project is the Relational paradigm.

Creating Notification Handler for sending email instead of do it inside command handler

Docker images: Unable to configure HTTPS endpoint

[{"_id":"66fefff6ad3c4128c70beb71","body":"I have same problem and I don't how fix that\r\nmy os is ubuntu22","issue_id":1714890490067,"origin_id":2118716541,"user_origin_id":45386071,"create_time":1716022552,"update_time":1716022567,"id":1727987702539,"updated_at":"2024-10-03T20:35:02.539000Z","created_at":"2024-10-03T20:35:02.539000Z"},{"_id":"66fefff6ad3c4128c70beb72","body":"this is a massive pain based on chatgpt the kestrel certificate and password need to be an env var I tried on my mac and also on windows","issue_id":1714890490067,"origin_id":2119014981,"user_origin_id":165957874,"create_time":1716070112,"update_time":1716070128,"id":1727987702546,"updated_at":"2024-10-03T20:35:02.546000Z","created_at":"2024-10-03T20:35:02.546000Z"},{"_id":"66fefff6ad3c4128c70beb74","body":"this should be fixed\r\n","issue_id":1714890490067,"origin_id":2119132022,"user_origin_id":101035374,"create_time":1716103213,"update_time":1716103213,"id":1727987702555,"updated_at":"2024-10-03T20:35:02.554000Z","created_at":"2024-10-03T20:35:02.554000Z"},{"_id":"66fefff6ad3c4128c70beb75","body":"let me pull again but I checked out the repo 2 days ago and I dont see any commits since","issue_id":1714890490067,"origin_id":2119138907,"user_origin_id":165957874,"create_time":1716104822,"update_time":1716104822,"id":1727987702559,"updated_at":"2024-10-03T20:35:02.558000Z","created_at":"2024-10-03T20:35:02.558000Z"},{"_id":"66fefff6ad3c4128c70beb76","body":"@BardiaYaghmaie after some tinkering this works when running from visual studio as it does some additional magic but running docker-compose -f docker-compose.yml -f docker-compose.override.yml up -d is missing a few things so I would recommend updating the docker compose overrides and the documentation ..like the hardcoded windows paths and the fact that rider or just VS Code are not an option make it hard to use ..I had to switch from my mac to my windows machine to get it working","issue_id":1714890490067,"origin_id":2119151653,"user_origin_id":165957874,"create_time":1716107494,"update_time":1716107494,"id":1727987702564,"updated_at":"2024-10-03T20:35:02.564000Z","created_at":"2024-10-03T20:35:02.564000Z"},{"_id":"66fefff6ad3c4128c70beb77","body":"Did you find any solution regarding the volumes set in docker-compose.override? I can't find 'usersecrets' and 'Https'. I can't find these two.\r\n","issue_id":1714890490067,"origin_id":2119206033,"user_origin_id":45386071,"create_time":1716119062,"update_time":1716119062,"id":1727987702568,"updated_at":"2024-10-03T20:35:02.568000Z","created_at":"2024-10-03T20:35:02.568000Z"},{"_id":"66fefff6ad3c4128c70beb78","body":"@mbehnasr for db services I had to add \r\n - POSTGRES_HOST_AUTH_METHOD=trust\r\n \r\n for the volumes on my mac its\r\n volumes:\r\n - ~\/.microsoft\/usersecrets:\/home\/app\/.microsoft\/usersecrets:ro\r\n - ~\/.microsoft\/devcerts:\/home\/app\/.aspnet\/https:ro\r\n \r\n but ask AI it helps\r\n \r\n this will still not solve the issues with https follow this article: https:\/\/learn.microsoft.com\/en-us\/aspnet\/core\/security\/docker-https?view=aspnetcore-8.0 ","issue_id":1714890490067,"origin_id":2119353652,"user_origin_id":165957874,"create_time":1716151213,"update_time":1716151213,"id":1727987702572,"updated_at":"2024-10-03T20:35:02.571000Z","created_at":"2024-10-03T20:35:02.571000Z"},{"_id":"66fefff6ad3c4128c70beb79","body":"this one worked for me and the diff is that visual studio configure and runs with the correct certs while otherwise you need to generate your certs with a password amd mount the location and also tell dotnet where to find them and whats the password\r\ndotnet dev-certs https -ep .\/certs\/aspnetapp.pfx -p SuperSecretPassword \r\n \r\n shopping.web:\r\n environment:\r\n - ASPNETCORE_ENVIRONMENT=Development\r\n - ASPNETCORE_HTTP_PORTS=8080\r\n - ASPNETCORE_HTTPS_PORTS=8081\r\n - ASPNETCORE_Kestrel__Certificates__Default__Path=\/https\/aspnetapp.pfx\r\n - ASPNETCORE_Kestrel__Certificates__Default__Password=SuperSecretPassword\r\n - ApiSettings__GatewayAddress=http:\/\/yarpapigateway:8080\r\n depends_on:\r\n - yarpapigateway\r\n ports:\r\n - \"6005:8080\"\r\n - \"6065:8081\"\r\n volumes:\r\n - .\/certs:\/https\/","issue_id":1714890490067,"origin_id":2119798916,"user_origin_id":165957874,"create_time":1716188323,"update_time":1716188323,"id":1727987702576,"updated_at":"2024-10-03T20:35:02.575000Z","created_at":"2024-10-03T20:35:02.575000Z"},{"_id":"66fefff6ad3c4128c70beb7b","body":"Hello there,\r\n\r\nI had the same problem with macOS M2 chip system, fixed the issue using given information under the ASP.NET documentation **Docker Compose with HTTPS** topic. [Link for the documentation topic](https:\/\/learn.microsoft.com\/en-us\/aspnet\/core\/security\/docker-compose-https?view=aspnetcore-8.0) In summary it's saying for macOS:\r\n\r\n_Generate certificate and configure local machine:_\r\n\r\n`dotnet dev-certs https -ep ${HOME}\/.aspnet\/https\/aspnetapp.pfx -p $CREDENTIAL_PLACEHOLDER$`\r\n`dotnet dev-certs https --trust`\r\n\r\n_dotnet dev-certs https --trust is only supported on macOS and Windows. You need to trust certificates on Linux in the way that is supported by your distribution. It is likely that you need to trust the certificate in your browser.\r\n\r\n_In the preceding commands, replace `$CREDENTIAL_PLACEHOLDER$` with a password._\r\n\r\n_Create a docker-compose.debug.yml file with the following content:_\r\n\r\n\r\nversion: '3.4'\r\n\r\nservices:\r\n webapp:\r\n image: mcr.microsoft.com\/dotnet\/samples:aspnetapp\r\n ports:\r\n - 80\r\n - 443\r\n environment:\r\n - ASPNETCORE_ENVIRONMENT=Development\r\n - ASPNETCORE_URLS=https:\/\/+:443;http:\/\/+:80\r\n **- ASPNETCORE_Kestrel__Certificates__Default__Password=password\r\n - ASPNETCORE_Kestrel__Certificates__Default__Path=\/https\/aspnetapp.pfx**\r\n volumes:\r\n **- ~\/.aspnet\/https:\/https:ro**\r\n\r\n_the password specified in the docker compose file must match the password used for the certificate._\r\n\r\n_Start the container with ASP.NET Core configured for HTTPS:_\r\n`docker-compose -f \"docker-compose.yml\" up -d`\r\n\r\n\r\nAlso its my `docker_compose.yaml` file for an example:\r\n\r\n``` yaml\r\nservices:\r\n catalogdb:\r\n image: postgres\r\n container_name: catalogdb\r\n environment: \r\n - POSTGRES_USER=postgres\r\n - POSTGRES_PASSWORD=pass\r\n - POSTGRES_DB=CatalogDb\r\n restart: always\r\n ports:\r\n - \"5432:5432\"\r\n volumes:\r\n - postgres_catalog:\/var\/lib\/postgresql\/data\r\n catalog.api:\r\n image: catalog.api\r\n build:\r\n context: .\r\n dockerfile: Services\/Catalog\/Catalog.API\/Dockerfile\r\n environment:\r\n - ASPNETCORE_ENVIRONMENT=Development\r\n - ASPNETCORE_HTTP_PORTS=8080\r\n - ASPNETCORE_HTTPS_PORTS=8081\r\n - ConnectionStrings__Database=Server=catalogdb;Port=5432;Database=CatalogDb;User Id=postgres;Password=pass;Include Error Detail=true\r\n - ASPNETCORE_Kestrel__Certificates__Default__Path=\/https\/aspnetapp.pfx\r\n - ASPNETCORE_Kestrel__Certificates__Default__Password=useyourpassword\r\n depends_on:\r\n - catalogdb\r\n ports:\r\n - \"6000:8080\"\r\n - \"6060:8081\"\r\n volumes:\r\n - \/Users\/<youruserpath>\/.microsoft\/usersecrets:\/home\/app\/.microsoft\/usersecrets:ro\r\n - ~\/.aspnet\/https:\/https:ro\r\n\r\n```\r\n \r\n \r\n \r\n\r\n","issue_id":1714890490067,"origin_id":2280588420,"user_origin_id":80110747,"create_time":1723282063,"update_time":1723283042,"id":1727987702581,"updated_at":"2024-10-03T20:35:02.580000Z","created_at":"2024-10-03T20:35:02.580000Z"}] comment

Following the README file, everything works fine, but the main services like catalog, ordering, basket, etc., didn't worked due to HTTPS config exception. `Exception:` System.InvalidOperationException: Unable to configure HTTPS endpoint....

Cannot complete the docker compose on windows

[{"_id":"66feffd9ce5b51d58907c1dd","body":"@morbidod did you change the docker file anymore?\r\nwhat is your Dockec Container OS?","issue_id":1714890490072,"origin_id":1979528253,"user_origin_id":68272602,"create_time":1709668641,"update_time":1709668641,"id":1727987673685,"updated_at":"2024-10-03T20:34:33.685000Z","created_at":"2024-10-03T20:34:33.685000Z"}] comment

Here is the error: Step 8/17 : RUN dotnet restore "Services/Catalog/Catalog.API/Catalog.API.csproj" ---> [Warning] The requested image's platform (linux/amd64) does not match the detected host platform (windows/amd64) and no specific platform...

trust auth method on posgress to avoid password issues on macs in latest docker

In order to not change the scope of the project, I added a small change of maximum size to the frontend zipcode input. I added this item because it doesn't...

When a zipcode has a size greater than 5, a section occurs in the order api and the message becomes stagnant in RabbitMQ.

use mapper in create product for less and cleaner code structure extract functions in AuditableEntityIntercepterceptor into smaller functions reduce nesting in seed db

When trying to run the solution with docker compose from the root folder, via the following command ``` docker-compose -f src/docker-compose.yml -f src/docker-compose.override.yml up -d ``` I am getting the...