Starts in:
1 DAY
21 HRS
15 MIN
16 SEC
Starts in:
1 D
21 H
15 M
16 S
Open Closed

Error in production after updating to Abp 8.0.0 #6421


User avatar
0
icoretchi created
  • ABP Framework version: v8.0.0
  • UI Type: Blazor WASM
  • Database System: EF Core (SQL Server)
  • Tiered (for MVC) or Auth Server Separated (for Angular): microservice
  • Exception message and full stack trace:
  • Steps to reproduce the issue:

Hi,

After updating to v8.0.0 and following migration guides I am receiving the following error in production. Any suggestion?


14 Answer(s)
  • User Avatar
    0
    icoretchi created

    Hi,

    I've noticed that previously when the system has been deployed based on v7.4.4 the services in pods listening on http://[::]:80. But now in version 8.0.0 they are listening on http://[::]:8080. Could this be a problem? And by the way, if I'll set the ASPNETCORE_URLS=http://+:80;https://+:443 in Dockefiles, the services even fail to start.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    This is caused by net 8 breaking changes.

    WORKDIR /app
    EXPOSE 80
    EXPOSE 443
    ENV ASPNETCORE_URLS=http://+:80;https://+:443
    

    https://learn.microsoft.com/en-us/dotnet/core/compatibility/containers/8.0/aspnet-port

  • User Avatar
    0
    icoretchi created

    Hi,

    Yes I know and as I mentioned, I've tryied to set the ASPNETCORE_URLS variable but the applications failed to start. I've also changed all the ports to 8080 but I am receiving the same error.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    but the applications failed to start

    What are the error logs?

    You should try to change the port to 80 because the URLs in the database may be 80.

  • User Avatar
    0
    icoretchi created

    What do you mean URLs in the database may be 80?

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    The OpenIddict will store the PostLogoutRedirectUris, RedirectUris in the database. if you changed your app port you also need to update the database.

  • User Avatar
    0
    icoretchi created

    Hi,

    When I am setting the variables in Dockerfiles like the following: EXPOSE 80 EXPOSE 443 ENV ASPNETCORE_HTTP_PORTS=80 ENV ASPNETCORE_HTTPS_PORTS=443 ENV ASPNETCORE_URLS=http://+:80;https://+:443

    I am receiving the following errors:

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    You can try to set a dev HTTPS certificate for docker.

    https://learn.microsoft.com/en-us/aspnet/core/security/enforcing-ssl https://github.com/dotnet/AspNetCore.Docs/issues/6199

  • User Avatar
    0
    icoretchi created

    Hi,

    I wish you to deploy your upgraded to v8.0.0 eShopOnAbp to production kubernetes cluster and see if you face the same problems. Thanks

  • User Avatar
    0
    gterdem created
    Senior .NET Developer

    It seems you are trying to run your application on HTTPS inside the internal error that causes the problem. Try removing all the 443 exposing and run the application on HTTP. Ingress should handle the internal port HTTPS mapping.

    I'll try to create a public sample for .NET 8 local k8s deployment.

  • User Avatar
    0
    icoretchi created

    Hi,

    The system was succefully ran for months. The problems appeared after upgrading to Net 8. The exposing ports that you see is just minor changes that I am trying to do to handle the issues with default port in net 8 and the error that appeared. Everything is through ingreses acording to abp framework kubernetes manifests templates.

  • User Avatar
    0
    icoretchi created

    And by the way, if you are preparing the sample try to deploy to production cluster not to local one, because the manifests configuration usually are different. It could work local but not in production. We already face such problems.

    Thanks & Regards,

  • User Avatar
    0
    gterdem created
    Senior .NET Developer

    And by the way, if you are preparing the sample try to deploy to production cluster not to local one, because the manifests configuration usually are different. It could work local but not in production. We already face such problems.

    Thanks & Regards,

    Well, I can not deploy to production cluster. But there shouldn't be any differences between the local cluster other then DNS mapping and SSL generation.

    We will be publishing eShopOnAbp with the new version soon. But this issue is not related to ABP but the .NET 8 itself. Hence, I would suggest checking SO aswell. There should be others having the same problem already.

  • User Avatar
    0
    icoretchi created

    Hi,

    I've managed to configure the services. Setting the ASPNETCORE_URLS environment variables did not work for me and I didn't find why. So I decide to let the services run on the new port 8080, I've exposed port 8080 in the Dockerfiles and I've set for ClusterIP services targetPort to 8080 as well. And everything is running properly.

    Cheers.

Made with ❤️ on ABP v9.1.0-preview. Updated on November 20, 2024, 13:06