Skip to content

How to set the server name in Nginx? #225

Discussion options

You must be logged in to vote

I am afraid to say that I am not a big help with Nginx. Can you test it with Yellow 0.6.9?

You can also try the following catch-all server block in your Nginx configuration:

server {
    listen 80 default_server;
    server_name _;
    ...
}

... or use two server blocks, one for your static IP and one for localhost:

server {
    listen 80;
    server_name 1.2.3.4;
    ...
}

server {
    listen 80;
    server_name localhost;
    ...
}

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by annaesvensson
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #225 on December 27, 2020 00:35.