nginx showing default page on wan but not lan Announcing the arrival of Valued Associate #679:...

Is a manifold-with-boundary with given interior and non-empty boundary essentially unique?

Why was the term "discrete" used in discrete logarithm?

Why aren't air breathing engines used as small first stages

Why is black pepper both grey and black?

Does accepting a pardon have any bearing on trying that person for the same crime in a sovereign jurisdiction?

Output the ŋarâþ crîþ alphabet song without using (m)any letters

How to bypass password on Windows XP account?

Using et al. for a last / senior author rather than for a first author

How to recreate this effect in Photoshop?

How does cp -a work

What is the longest distance a 13th-level monk can jump while attacking on the same turn?

Should I discuss the type of campaign with my players?

Is there a service that would inform me whenever a new direct route is scheduled from a given airport?

What is the musical term for a note that continously plays through a melody?

Antler Helmet: Can it work?

When to stop saving and start investing?

Why one of virtual NICs called bond0?

The logistics of corpse disposal

Can Pao de Queijo, and similar foods, be kosher for Passover?

Disable hyphenation for an entire paragraph

Is 1 ppb equal to 1 μg/kg?

Check which numbers satisfy the condition [A*B*C = A! + B! + C!]

How to find all the available tools in macOS terminal?

What does the "x" in "x86" represent?



nginx showing default page on wan but not lan



Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)
Come Celebrate our 10 Year Anniversary!Blank Page: wordpress on nginx+php-fpmNGINX don't parse .php5 as .phpLaravel 4.1 on nginx routes error 404Nginx/Apache: set HSTS only if X-Forwarded-Proto is httpsOCSP validation - unable to get local issuer certificatenginx rewrite throw 404 with last and breakCodeIgniter nginx rewrite rules for i8ln URL'snginx seems to be ignoring ssl_ciphers settingSSL_read() failed (SSL: error:140943F2:SSL routines:SSL3_READ_BYTES:sslv3 error in nginxNGINX virtual host config for Magento2 in a subfolder





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}







0















When I access my nginx webserver on lan, it shows me the correct webpage I have setup. For some reason when I try to connect to it through a different network, it returns the default nginx page. It is still able to connect, it just displays the wrong page.



How would I fix this issue so it shows the webpage on both lan and wan? Port forward on my router is functional and is not the issue. The connection goes through a cloudflare proxy, could this be the issue?



Here is my configuration file:



server_tokens off;

server {
listen 80;
server_name <domain>;
if($http_x_forwarded_proto = "http"){
return 301 https://$server_name$request_uri;
}
}

server {
listen 443 ssl http2;
server_name <domain>;

root /var/www/pterodactyl/public;
index index.php;

access_log /var/log/nginx/pterodactyl.app-access.log;
error_log /var/log/nginx/pterodactyl.app-error.log error;

# allow larger file uploads and longer script runtimes
client_max_body_size 100m;
client_body_timeout 120s;

sendfile off;

# SSL Configuration
ssl_certificate /etc/letsencrypt/live/<domain>/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/<domain>/privkey.pem;
ssl_session_cache shared:SSL:10m;
ssl_protocols TLSv1.2;
ssl_ciphers 'ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256';
ssl_prefer_server_ciphers on;

# See https://hstspreload.org/ before uncommenting the line below.
# add_header Strict-Transport-Security "max-age=15768000; preload;";
add_header X-Content-Type-Options nosniff;
add_header X-XSS-Protection "1; mode=block";
add_header X-Robots-Tag none;
add_header Content-Security-Policy "frame-ancestors 'self'";
add_header X-Frame-Options DENY;
add_header Referrer-Policy same-origin;

location / {
try_files $uri $uri/ /index.php?$query_string;
}

location ~ .php$ {
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_pass unix:/run/php/php7.2-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param PHP_VALUE "upload_max_filesize = 100M n post_max_size=100M";
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param HTTP_PROXY "";
fastcgi_intercept_errors off;
fastcgi_buffer_size 16k;
fastcgi_buffers 4 16k;
fastcgi_connect_timeout 300;
fastcgi_send_timeout 300;
fastcgi_read_timeout 300;
include /etc/nginx/fastcgi_params;
}

location ~ /.ht {
deny all;
}
}








share





























    0















    When I access my nginx webserver on lan, it shows me the correct webpage I have setup. For some reason when I try to connect to it through a different network, it returns the default nginx page. It is still able to connect, it just displays the wrong page.



    How would I fix this issue so it shows the webpage on both lan and wan? Port forward on my router is functional and is not the issue. The connection goes through a cloudflare proxy, could this be the issue?



    Here is my configuration file:



    server_tokens off;

    server {
    listen 80;
    server_name <domain>;
    if($http_x_forwarded_proto = "http"){
    return 301 https://$server_name$request_uri;
    }
    }

    server {
    listen 443 ssl http2;
    server_name <domain>;

    root /var/www/pterodactyl/public;
    index index.php;

    access_log /var/log/nginx/pterodactyl.app-access.log;
    error_log /var/log/nginx/pterodactyl.app-error.log error;

    # allow larger file uploads and longer script runtimes
    client_max_body_size 100m;
    client_body_timeout 120s;

    sendfile off;

    # SSL Configuration
    ssl_certificate /etc/letsencrypt/live/<domain>/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/<domain>/privkey.pem;
    ssl_session_cache shared:SSL:10m;
    ssl_protocols TLSv1.2;
    ssl_ciphers 'ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256';
    ssl_prefer_server_ciphers on;

    # See https://hstspreload.org/ before uncommenting the line below.
    # add_header Strict-Transport-Security "max-age=15768000; preload;";
    add_header X-Content-Type-Options nosniff;
    add_header X-XSS-Protection "1; mode=block";
    add_header X-Robots-Tag none;
    add_header Content-Security-Policy "frame-ancestors 'self'";
    add_header X-Frame-Options DENY;
    add_header Referrer-Policy same-origin;

    location / {
    try_files $uri $uri/ /index.php?$query_string;
    }

    location ~ .php$ {
    fastcgi_split_path_info ^(.+.php)(/.+)$;
    fastcgi_pass unix:/run/php/php7.2-fpm.sock;
    fastcgi_index index.php;
    include fastcgi_params;
    fastcgi_param PHP_VALUE "upload_max_filesize = 100M n post_max_size=100M";
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    fastcgi_param HTTP_PROXY "";
    fastcgi_intercept_errors off;
    fastcgi_buffer_size 16k;
    fastcgi_buffers 4 16k;
    fastcgi_connect_timeout 300;
    fastcgi_send_timeout 300;
    fastcgi_read_timeout 300;
    include /etc/nginx/fastcgi_params;
    }

    location ~ /.ht {
    deny all;
    }
    }








    share

























      0












      0








      0








      When I access my nginx webserver on lan, it shows me the correct webpage I have setup. For some reason when I try to connect to it through a different network, it returns the default nginx page. It is still able to connect, it just displays the wrong page.



      How would I fix this issue so it shows the webpage on both lan and wan? Port forward on my router is functional and is not the issue. The connection goes through a cloudflare proxy, could this be the issue?



      Here is my configuration file:



      server_tokens off;

      server {
      listen 80;
      server_name <domain>;
      if($http_x_forwarded_proto = "http"){
      return 301 https://$server_name$request_uri;
      }
      }

      server {
      listen 443 ssl http2;
      server_name <domain>;

      root /var/www/pterodactyl/public;
      index index.php;

      access_log /var/log/nginx/pterodactyl.app-access.log;
      error_log /var/log/nginx/pterodactyl.app-error.log error;

      # allow larger file uploads and longer script runtimes
      client_max_body_size 100m;
      client_body_timeout 120s;

      sendfile off;

      # SSL Configuration
      ssl_certificate /etc/letsencrypt/live/<domain>/fullchain.pem;
      ssl_certificate_key /etc/letsencrypt/live/<domain>/privkey.pem;
      ssl_session_cache shared:SSL:10m;
      ssl_protocols TLSv1.2;
      ssl_ciphers 'ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256';
      ssl_prefer_server_ciphers on;

      # See https://hstspreload.org/ before uncommenting the line below.
      # add_header Strict-Transport-Security "max-age=15768000; preload;";
      add_header X-Content-Type-Options nosniff;
      add_header X-XSS-Protection "1; mode=block";
      add_header X-Robots-Tag none;
      add_header Content-Security-Policy "frame-ancestors 'self'";
      add_header X-Frame-Options DENY;
      add_header Referrer-Policy same-origin;

      location / {
      try_files $uri $uri/ /index.php?$query_string;
      }

      location ~ .php$ {
      fastcgi_split_path_info ^(.+.php)(/.+)$;
      fastcgi_pass unix:/run/php/php7.2-fpm.sock;
      fastcgi_index index.php;
      include fastcgi_params;
      fastcgi_param PHP_VALUE "upload_max_filesize = 100M n post_max_size=100M";
      fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      fastcgi_param HTTP_PROXY "";
      fastcgi_intercept_errors off;
      fastcgi_buffer_size 16k;
      fastcgi_buffers 4 16k;
      fastcgi_connect_timeout 300;
      fastcgi_send_timeout 300;
      fastcgi_read_timeout 300;
      include /etc/nginx/fastcgi_params;
      }

      location ~ /.ht {
      deny all;
      }
      }








      share














      When I access my nginx webserver on lan, it shows me the correct webpage I have setup. For some reason when I try to connect to it through a different network, it returns the default nginx page. It is still able to connect, it just displays the wrong page.



      How would I fix this issue so it shows the webpage on both lan and wan? Port forward on my router is functional and is not the issue. The connection goes through a cloudflare proxy, could this be the issue?



      Here is my configuration file:



      server_tokens off;

      server {
      listen 80;
      server_name <domain>;
      if($http_x_forwarded_proto = "http"){
      return 301 https://$server_name$request_uri;
      }
      }

      server {
      listen 443 ssl http2;
      server_name <domain>;

      root /var/www/pterodactyl/public;
      index index.php;

      access_log /var/log/nginx/pterodactyl.app-access.log;
      error_log /var/log/nginx/pterodactyl.app-error.log error;

      # allow larger file uploads and longer script runtimes
      client_max_body_size 100m;
      client_body_timeout 120s;

      sendfile off;

      # SSL Configuration
      ssl_certificate /etc/letsencrypt/live/<domain>/fullchain.pem;
      ssl_certificate_key /etc/letsencrypt/live/<domain>/privkey.pem;
      ssl_session_cache shared:SSL:10m;
      ssl_protocols TLSv1.2;
      ssl_ciphers 'ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256';
      ssl_prefer_server_ciphers on;

      # See https://hstspreload.org/ before uncommenting the line below.
      # add_header Strict-Transport-Security "max-age=15768000; preload;";
      add_header X-Content-Type-Options nosniff;
      add_header X-XSS-Protection "1; mode=block";
      add_header X-Robots-Tag none;
      add_header Content-Security-Policy "frame-ancestors 'self'";
      add_header X-Frame-Options DENY;
      add_header Referrer-Policy same-origin;

      location / {
      try_files $uri $uri/ /index.php?$query_string;
      }

      location ~ .php$ {
      fastcgi_split_path_info ^(.+.php)(/.+)$;
      fastcgi_pass unix:/run/php/php7.2-fpm.sock;
      fastcgi_index index.php;
      include fastcgi_params;
      fastcgi_param PHP_VALUE "upload_max_filesize = 100M n post_max_size=100M";
      fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      fastcgi_param HTTP_PROXY "";
      fastcgi_intercept_errors off;
      fastcgi_buffer_size 16k;
      fastcgi_buffers 4 16k;
      fastcgi_connect_timeout 300;
      fastcgi_send_timeout 300;
      fastcgi_read_timeout 300;
      include /etc/nginx/fastcgi_params;
      }

      location ~ /.ht {
      deny all;
      }
      }






      nginx ubuntu-18.04





      share












      share










      share



      share










      asked 3 mins ago









      Matthew NMatthew N

      10613




      10613






















          0






          active

          oldest

          votes












          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "2"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f963218%2fnginx-showing-default-page-on-wan-but-not-lan%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes
















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Server Fault!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f963218%2fnginx-showing-default-page-on-wan-but-not-lan%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          As a Security Precaution, the user account has been locked The Next CEO of Stack OverflowMS...

          Список ссавців Італії Природоохоронні статуси | Список |...

          Українські прізвища Зміст Історичні відомості |...