How to deploy .net core website in linux | Hosting .net core website in ubuntu using nginx server

preview_player
Показать описание
Hi there, in this video I have described how to install nginx server and how to deploy asp .net core web app in linux machine. For this i have used nginx server as a reverse proxy server and asp .net mvc core for creating a web app.
Topics covered in this video:
How to deploy .net core app in linux.
How to install nginx server in linux machine.
===========================================================
server {
listen 80;
location / {
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection keep-alive;
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}

--------------
[Unit]
Description= mvcnew webapp
[Service]
WorkingDirectory=/var/www/app1
Restart=always
# Restart service after 10 seconds if the dotnet service crashes:
RestartSec=10
SyslogIdentifier=mvcnew
Environment=ASPNETCORE_ENVIRONMENT=Production

[Install]

....................................................................

Previous videos:
1. Asp.Net Core MVC Web App CRUD with EF Core

2. How to use SQL-Server with VS Code in Ubuntu.

Other links:
.......................................................
connect with me
..........................................
Become a supporter:
.......................................................
connect with me
..........................................
Become a supporter:
Рекомендации по теме
Комментарии
Автор

holy shit thank you so much! worked perfectly for blazor

willgale
Автор

Great video. Short and to the point. Thank you

asharzaman
Автор

I am not able to connect from aws ec2 linux machine's .net core web api to remote Sql Server hosted on different aws machine

harshilgandhigoogle
Автор

I did it for a website hosted on aws and i got after all the setup it is showing me error 463 its bcz of X-Forwarded-For to be set, can you tell me anyway to set that to my client side

umangyadav
Автор

Thank you Ravindra, appreciate indeed !

parrivera
Автор

Hi. I want to use the path like this localhost/{appName}. I dont want to use default root localhost. How can I do this? Thanks :)

anlkeskin
Автор

Great! This works like charms.. Thanks for this!

alifrahmanputranda
Автор

MSBUILD : error MSB1003: Specify a project or solution file. The current working directory does not contain a project or solution file.

felipecampos
Автор

Great! Can't we deploy it without any reverse proxy like nginx or apache? We know reverse proxy handles queuing mechanism. Is there any alternative for handling queuing mechanism without using reverse proxy?

tharakakundla
Автор

How can we host multiple web api in nginx using same elestic ip

rahulsen
Автор

it's quite easy. thank you for sharing.

yohanespradono
Автор

Can you access it from other devices by server IP address.

toonthoon
Автор

Now, how do I connect to SQL Server hosted in Windows? 😂 Looking for work around but still no luck..

alifrahmanputranda
Автор

Tank you, But can you show in a video, How can I configure litespeed for hosing asp.net core ?Tank you

محسن-ههث