0

Is it possible to deploy .Net app and React app (in subfolder) on plesk hosting at the same time ? Any solutions or better ways for me to do it, thanks

enter image description herei have built and published my .Net app on Plesk and it works fine. I would like to create a subfolder then publish my React app in there. How can i access my React app by route or somethings else ?

1
  • Aren't you using the UseSpa middleware? Otherwise it'll be hard since you would have to host both your ASP.NET Core app and react app, which both run on a different port, or you'd have to move the frontend in the wwwroot folder, or use a proxy... Commented Apr 13, 2023 at 15:10

1 Answer 1

0

I have the same issue and there is my solution:

  1. You should implement your separate React app to the Visual Studio in your current .Net project. Follow this instruction. Make sure that weatherforecast is working
  2. Configure your Program.cs like in this answer. Configure setupProxy.js and set const context = ["/",];
  3. Deploy to the Plesk. Check your set up of "nodejs" module, should be like in the picture enter image description here. Node Js in the Plesk must be disabled

Your React app will be in the wwwroot folder

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.