- Frontend with ReactJS
- Backend with .NET 6
Backend with .NET 6
$dotnet run --project src/src.csproj
info: Microsoft.Hosting.Lifetime[14]
Now listening on: https://localhost:7177
info: Microsoft.Hosting.Lifetime[14]
Now listening on: http://localhost:5070
info: Microsoft.Hosting.Lifetime[0]
Application started. Press Ctrl+C to shut down.
Access to APIs
- API Document with Swagger :: https://localhost:7177/swagger/index.html
- Call API :: https://localhost:7177/WeatherForecast
Running .NET 6 with Docker
$docker-compose build backend
$docker-compose up -d backend
$docker-compose ps
NAME COMMAND SERVICE STATUS PORTS
demo-dotnet-react-backend-1 "dotnet src.dll" backend running
Access to APIs
- Call API :: http://localhost:9999/WeatherForecast
Frontent with ReactJS
$cd frontend
$npm install
$npm run dev
Access with url = http://localhost:5173/
$npm run build
Deploy files and folders ./dist
to web server such as NGINX
$docker-compose build frontend
$docker-compose up -d frontend
$docker-compose ps
NAME COMMAND SERVICE STATUS PORTS
demo-dotnet-react-backend-1 "dotnet src.dll" backend running
Access with url = http://localhost:8888