C
C#16mo ago
tymonello

❔ Blazor communicate with WebAPI on localhost server

Hello, I want to start making a staging environment for my application, I got a WebAPI ready and working, and I installed it on a ubuntu server in my local network. But when I am calling it from Blazor, I am getting an Error: System.Net.Http.HttpRequestException: The SSL connection could not be established. It works well when I run both API and Blazor on my computer. I have configured NGINX, I can call the API from a browser, first by IP address, then I added it to a DNS on a local domain, it works like that too. I created a self-signed certificate. Because certbot doesn't work for .local domains and IP addresses. But I somehow can't really make it all work together. Sometimes the API works when I add the port it runs on, so it has no certificate, other times it works via the NGINX, when I just enter the address without ports, and shows the certificate in the browser I created, but Blazor still shows the same error. I probably messed up everything by now, so I am looking for a good guide on how to run an API on a Ubuntu server, so that it is exposed on port 80 and 443, and that Blazor can communicate with it.
7 Replies
Relevant
Relevant16mo ago
Not using Docker, I assume?
tymonello
tymonello16mo ago
not using docker
Relevant
Relevant16mo ago
And this is web assembly? Also assuming it's purely an SSL issue. Have you tried disabling SSL to make sure it's isolated to something certificate related?
tymonello
tymonello16mo ago
Blazor ServerSide Disable SSL where? In Blazor? In the API?
Accord
Accord16mo ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.
tymonello
tymonello16mo ago
No it was not resolved
Accord
Accord16mo ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.
Want results from more Discord servers?
Add your server
More Posts
❔ Get Pixels cords from Image by their colorHey, I'm writing a game and I need to get the pixels cords by their colors from an Image, I tried us❔ Storing & retrieving face encodings to compareWhat's the best way to store face encodings (an array of size 128 and type float64) in a database an❔ New to C# and am trying to make a Minesweeper console appI am having trouble with my "UpdateBoard" method and I can not seem to figure out what the problem i❔ System.Data.OleDb.OleDbException: 'Could not find installable ISAM.' errorHi anyone can help me? i start the test and i got System.Data.OleDb.OleDbException: 'Could not find ❔ Accounting for Daylight Savings Time skips at runtimeMy Discord bot I am developing has a reminder system which utilizes <https://github.com/robbell/nChr✅ I need to put an invalid choice in my programI need to make the program repeat if they did not input a valid response of yes or no❔ My project runs successfully but doesn't load ( works fine when I run it without debugging )my project was working fine but suddenly whenever I run it it keeps loading without showing anythingOnly assignment, call, increment, decrement, await, and new object expressions can be used as a statim a noob and why cant i make my console make a beep sound? I didnt understand the error msg❔ multiple Async responsesSo im trying to use async for the first time, i am making a few api requests one after the other, thInvoke Event on boolean set in systemclassI have my own TcpClient class that inherits TcpClient and I wanna invoke an event when one of the bo