Hello,
I'm encountering an issue with my server / nginx configuration and although I've searched this forum and checked other resources, I couldn't find a working solution.
So, I'm using a Ubuntu 16.04 server with nginx version 1.14.0 installed, where I'm hosting 3 websites (shared IP).
Default server configuration:
server {
listen 80 default_server;
listen [::]:80 default_server;
server_name _;
return 444;
}
Everytime I point a new domain name to the shared IP, the new domain gets redirected to the first website / account created on the server, although I would just want that 444 header returned.
The other active websites are using following configuration:
server {
listen 443 ssl http2;
server_name <domain name>;
root "/home/<username>/public_html";
# Specify a charset
charset utf-8;
# Basic configuration
include /etc/nginx/config/basic.conf;
# SSL configuration
include /etc/nginx/config/directive-only/ssl.conf;
ssl_certificate /home/<username>/ssl.crt;
ssl_certificate_key /home/<username>/ssl.key;
}
What would you suggest?
Thanks
I'm encountering an issue with my server / nginx configuration and although I've searched this forum and checked other resources, I couldn't find a working solution.
So, I'm using a Ubuntu 16.04 server with nginx version 1.14.0 installed, where I'm hosting 3 websites (shared IP).
Default server configuration:
server {
listen 80 default_server;
listen [::]:80 default_server;
server_name _;
return 444;
}
Everytime I point a new domain name to the shared IP, the new domain gets redirected to the first website / account created on the server, although I would just want that 444 header returned.
The other active websites are using following configuration:
server {
listen 443 ssl http2;
server_name <domain name>;
root "/home/<username>/public_html";
# Specify a charset
charset utf-8;
# Basic configuration
include /etc/nginx/config/basic.conf;
# SSL configuration
include /etc/nginx/config/directive-only/ssl.conf;
ssl_certificate /home/<username>/ssl.crt;
ssl_certificate_key /home/<username>/ssl.key;
}
What would you suggest?
Thanks