Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #243050

Nginx and ASP.Net Core

From Patrick Kirk <patrick@kirks.net>
Newsgroups linux.debian.user
Subject Nginx and ASP.Net Core
Date 2021-12-13 12:40 +0100
Message-ID <DtRGN-4Fe-1@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

Hi all,

I am trying to run an ASP.Net Core site on my hosted Debian box and I seem
to have messed up the configuration.  All attempts to reach the page on
port 80 get 403 Forbidden messages.

My error log says: pk@debian-s-websites:~$ sudo tail -f
/var/log/nginx/error.log 2021/12/13 06:27:24 [error] 17999#17999: *675
directory index of "/var/www/cxxxn.org/" is forbidden, client: 213.7.43.53,
server: cxxxn.org, request: "GET / HTTP/1.1", host: "www.cxxxn.org"

If I try lynx http://localhost:5000 locally I get a perfect session. So
kestrel is working but nginx is not configured correctly. I think the
mistake is in my the config file for cxxxn.org has a line saying: "index
index.html index.htm index.nginx-debian.html" To test this, I put a <html>Hello
World</html> file in the root folder and it was served up correctly. If I
then try http://cxxxn.org/Privacy I get a 404 error.

Does anyone know if my guess that the "index" line in the configuration is
the problem is correct?

How can I configure Nginx to serve content from Asp.Net Core where there is
no static html file being generated?

Thanks in advance.

Back to linux.debian.user | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

Nginx and ASP.Net Core Patrick Kirk <patrick@kirks.net> - 2021-12-13 12:40 +0100
  Re: Nginx and ASP.Net Core Patrick Kirk <patrick@kirks.net> - 2021-12-13 13:10 +0100
    Re: Nginx and ASP.Net Core Dan Ritter <dsr@randomstring.org> - 2021-12-13 13:40 +0100
  Re: Nginx and ASP.Net Core Dan Ritter <dsr@randomstring.org> - 2021-12-13 13:10 +0100

csiph-web