How hosting and deploying my application in Folder?

sblb 1,166 Reputation points
2023-05-29T11:34:21.9266667+00:00

Hi,

I made an application with blazor wasm hosted .net6 core.

I would like to publish it in local Folder and have acces to my app in my browser.

Also, I would like that some users can use my app in browser.

First I would like to know if it's possible?

I published it to use Folder item and I run .exe to launch my app.

I obtain the following screen and copy/paste the url : https://localhost:5001 the app working well

I would like to know if I can create the specific url of my app, e.g https://myapp.com, to avoid to launch .exe and that the user launch the app direcly in browser.

User's image

Thanks in advance to your support

Blazor
Blazor
A free and open-source web framework that enables developers to create web apps using C# and HTML being developed by Microsoft.
1,403 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Bruce (SqlWork.com) 56,931 Reputation points
    2023-05-29T15:42:15.1633333+00:00

    You need a web server to host the blazor app. You can deploy the app to a web server configured to host asp.net core, or as you have found, you can run the the asp.net core app directly and it acts as a web server.

    to allow other users, typically you would pick a web hosting service and deploy the app to that service. Optionally you can purchase a custom domain name.


  2. sblb 1,166 Reputation points
    2023-05-30T14:09:08.16+00:00

    Hi,

    I publish my application in Folder via VStudio and after I copy/paste in folder in IIS.

    conifg file is

    <?xml version="1.0" encoding="utf-8"?>
    <configuration>
      <location path="." inheritInChildApplications="false">
        <system.webServer>
          <handlers>
            <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
          </handlers>
          <aspNetCore processPath="dotnet" arguments=".\FollowUpDash.Server.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" />
        </system.webServer>
      </location>
    </configuration>
    <!--ProjectGuid: bd493077-e227-4c45-b7f2-eb166fc626f9-->
    

    It's doesn't work

    How I can do desploy and host?