Can't visit service other than server machine, a seperated backend and frontend projectCan't visit server on some port from other machine in the same intranetloadbalancing with difference nginx location context and backend server contextDoes it matter if nginx frontend (rev proxy) uses different SSL certificate than backend server?Nginx load balancing redirects to upstream “name”nginx auth_basic 401 htpasswdQ: Strange web traffic - Is this an attack?How to have frontend, on s3, and backend on another server with the same domainDocker, Nginx and PHP7: ERROR 111 Connection refused while connecting to upstreamDid someone succeeded in getting to my server?Redirect in nginx port not showing upNGINX reverse-proxy exposing backend server IP address and protocol

What was Bran's plan to kill the Night King?

SafeCracker #3 - We've Been Blocked

Where are the "shires" in the UK?

Are Finitely generated modules over a ring also finitely generated over a subring containing the identity?

What if the end-user didn't have the required library?

Can I use a fetch land to shuffle my deck while the opponent has Ashiok, Dream Render in play?

How to increase the size of the cursor in Lubuntu 19.04?

Frequency of specific viral sequence in .BAM or .fastq

How to adjust tikz picture so it fits to current size of a table cell?

29er Road Tire?

Word for Food that's Gone 'Bad', but is Still Edible?

What was the first story to feature the plot "the monsters were human all along"?

Is there an official reason for not adding a post-credits scene?

Has the Hulk always been able to talk?

Where can I go to avoid planes overhead?

US born but as a child of foreign diplomat

Floor of Riemann zeta function

In Stroustrup's example, what does this colon mean in `return 1 : 2`? It's not a label or ternary operator

Word meaning as function of the composition of its phonemes

A factorization game

Upside-Down Pyramid Addition...REVERSED!

How long would it take for people to notice a mass disappearance?

Identifying characters

What to use instead of cling film to wrap pastry



Can't visit service other than server machine, a seperated backend and frontend project


Can't visit server on some port from other machine in the same intranetloadbalancing with difference nginx location context and backend server contextDoes it matter if nginx frontend (rev proxy) uses different SSL certificate than backend server?Nginx load balancing redirects to upstream “name”nginx auth_basic 401 htpasswdQ: Strange web traffic - Is this an attack?How to have frontend, on s3, and backend on another server with the same domainDocker, Nginx and PHP7: ERROR 111 Connection refused while connecting to upstreamDid someone succeeded in getting to my server?Redirect in nginx port not showing upNGINX reverse-proxy exposing backend server IP address and protocol






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








0















I have asked a related question but has solved it already.

Using nginx provided a reverse proxy.

The config file is taking from project document, I paste it below.



Current situation is:

The backend service is working on port 8080. And the front end is working on port 9001.



$ netstat -anp |grep 8080
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
tcp6 0 0 :::8080 :::* LISTEN 26707/java

$ netstat -anp |grep 9001
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
tcp 0 0 127.0.0.1:9001 0.0.0.0:* LISTEN 12130/grunt


I can visit the localhost:9001 on machine A where the service is running.
While visits from any other machine in the same LAN. It shows the error page. If go with Inspect, there is a message in the error page.



Cannot open document for: /eplmp-server-rest/api/auth/providers from http://192.168.1.164:8989/


192.168.1.164 is the machine A's IP address.
/eplmp-server-rest/api/* should be the endpoint serve by the backend service.



The XHR Network Headers from machine A.



General
Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers
Request Method: GET
Status Code: 200 OK
Remote Address: [::1]:8080
Referrer Policy: no-referrer-when-downgrade

Requst Headers
Provisional headers are shown
Accept: application/json, text/javascript, */*; q=0.01
Origin: http://localhost:9001
Referer: http://localhost:9001/
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36


from another machine in the same LAN



Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers
Referrer Policy: no-referrer-when-downgrade

Provisional headers are shown
Accept: application/json, text/javascript, /; q=0.01
Origin: http://192.168.1.164:8989
Referer: http://192.168.1.164:8989/
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36


The related nginx config file.



# Simple http proxy
server
listen 8989;
server_name localhost;

# Static grunt server
location /
# Use grunt server (require grunt serve command)
proxy_pass http://localhost:9001;

# OR serve static files directly :
# charset utf-8;
# root /path/to/docdoku-web-front/dist;
# expires 0d;
# access_log off;


# Webservices REST
location /api
proxy_pass http://localhost:8080;


# Websocket application
location /ws
proxy_pass http://localhost:8080/ws;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_read_timeout 7200s;











share|improve this question






























    0















    I have asked a related question but has solved it already.

    Using nginx provided a reverse proxy.

    The config file is taking from project document, I paste it below.



    Current situation is:

    The backend service is working on port 8080. And the front end is working on port 9001.



    $ netstat -anp |grep 8080
    (Not all processes could be identified, non-owned process info
    will not be shown, you would have to be root to see it all.)
    tcp6 0 0 :::8080 :::* LISTEN 26707/java

    $ netstat -anp |grep 9001
    (Not all processes could be identified, non-owned process info
    will not be shown, you would have to be root to see it all.)
    tcp 0 0 127.0.0.1:9001 0.0.0.0:* LISTEN 12130/grunt


    I can visit the localhost:9001 on machine A where the service is running.
    While visits from any other machine in the same LAN. It shows the error page. If go with Inspect, there is a message in the error page.



    Cannot open document for: /eplmp-server-rest/api/auth/providers from http://192.168.1.164:8989/


    192.168.1.164 is the machine A's IP address.
    /eplmp-server-rest/api/* should be the endpoint serve by the backend service.



    The XHR Network Headers from machine A.



    General
    Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers
    Request Method: GET
    Status Code: 200 OK
    Remote Address: [::1]:8080
    Referrer Policy: no-referrer-when-downgrade

    Requst Headers
    Provisional headers are shown
    Accept: application/json, text/javascript, */*; q=0.01
    Origin: http://localhost:9001
    Referer: http://localhost:9001/
    User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36


    from another machine in the same LAN



    Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers
    Referrer Policy: no-referrer-when-downgrade

    Provisional headers are shown
    Accept: application/json, text/javascript, /; q=0.01
    Origin: http://192.168.1.164:8989
    Referer: http://192.168.1.164:8989/
    User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36


    The related nginx config file.



    # Simple http proxy
    server
    listen 8989;
    server_name localhost;

    # Static grunt server
    location /
    # Use grunt server (require grunt serve command)
    proxy_pass http://localhost:9001;

    # OR serve static files directly :
    # charset utf-8;
    # root /path/to/docdoku-web-front/dist;
    # expires 0d;
    # access_log off;


    # Webservices REST
    location /api
    proxy_pass http://localhost:8080;


    # Websocket application
    location /ws
    proxy_pass http://localhost:8080/ws;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "upgrade";
    proxy_read_timeout 7200s;











    share|improve this question


























      0












      0








      0








      I have asked a related question but has solved it already.

      Using nginx provided a reverse proxy.

      The config file is taking from project document, I paste it below.



      Current situation is:

      The backend service is working on port 8080. And the front end is working on port 9001.



      $ netstat -anp |grep 8080
      (Not all processes could be identified, non-owned process info
      will not be shown, you would have to be root to see it all.)
      tcp6 0 0 :::8080 :::* LISTEN 26707/java

      $ netstat -anp |grep 9001
      (Not all processes could be identified, non-owned process info
      will not be shown, you would have to be root to see it all.)
      tcp 0 0 127.0.0.1:9001 0.0.0.0:* LISTEN 12130/grunt


      I can visit the localhost:9001 on machine A where the service is running.
      While visits from any other machine in the same LAN. It shows the error page. If go with Inspect, there is a message in the error page.



      Cannot open document for: /eplmp-server-rest/api/auth/providers from http://192.168.1.164:8989/


      192.168.1.164 is the machine A's IP address.
      /eplmp-server-rest/api/* should be the endpoint serve by the backend service.



      The XHR Network Headers from machine A.



      General
      Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers
      Request Method: GET
      Status Code: 200 OK
      Remote Address: [::1]:8080
      Referrer Policy: no-referrer-when-downgrade

      Requst Headers
      Provisional headers are shown
      Accept: application/json, text/javascript, */*; q=0.01
      Origin: http://localhost:9001
      Referer: http://localhost:9001/
      User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36


      from another machine in the same LAN



      Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers
      Referrer Policy: no-referrer-when-downgrade

      Provisional headers are shown
      Accept: application/json, text/javascript, /; q=0.01
      Origin: http://192.168.1.164:8989
      Referer: http://192.168.1.164:8989/
      User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36


      The related nginx config file.



      # Simple http proxy
      server
      listen 8989;
      server_name localhost;

      # Static grunt server
      location /
      # Use grunt server (require grunt serve command)
      proxy_pass http://localhost:9001;

      # OR serve static files directly :
      # charset utf-8;
      # root /path/to/docdoku-web-front/dist;
      # expires 0d;
      # access_log off;


      # Webservices REST
      location /api
      proxy_pass http://localhost:8080;


      # Websocket application
      location /ws
      proxy_pass http://localhost:8080/ws;
      proxy_http_version 1.1;
      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection "upgrade";
      proxy_read_timeout 7200s;











      share|improve this question
















      I have asked a related question but has solved it already.

      Using nginx provided a reverse proxy.

      The config file is taking from project document, I paste it below.



      Current situation is:

      The backend service is working on port 8080. And the front end is working on port 9001.



      $ netstat -anp |grep 8080
      (Not all processes could be identified, non-owned process info
      will not be shown, you would have to be root to see it all.)
      tcp6 0 0 :::8080 :::* LISTEN 26707/java

      $ netstat -anp |grep 9001
      (Not all processes could be identified, non-owned process info
      will not be shown, you would have to be root to see it all.)
      tcp 0 0 127.0.0.1:9001 0.0.0.0:* LISTEN 12130/grunt


      I can visit the localhost:9001 on machine A where the service is running.
      While visits from any other machine in the same LAN. It shows the error page. If go with Inspect, there is a message in the error page.



      Cannot open document for: /eplmp-server-rest/api/auth/providers from http://192.168.1.164:8989/


      192.168.1.164 is the machine A's IP address.
      /eplmp-server-rest/api/* should be the endpoint serve by the backend service.



      The XHR Network Headers from machine A.



      General
      Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers
      Request Method: GET
      Status Code: 200 OK
      Remote Address: [::1]:8080
      Referrer Policy: no-referrer-when-downgrade

      Requst Headers
      Provisional headers are shown
      Accept: application/json, text/javascript, */*; q=0.01
      Origin: http://localhost:9001
      Referer: http://localhost:9001/
      User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36


      from another machine in the same LAN



      Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers
      Referrer Policy: no-referrer-when-downgrade

      Provisional headers are shown
      Accept: application/json, text/javascript, /; q=0.01
      Origin: http://192.168.1.164:8989
      Referer: http://192.168.1.164:8989/
      User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.103 Safari/537.36


      The related nginx config file.



      # Simple http proxy
      server
      listen 8989;
      server_name localhost;

      # Static grunt server
      location /
      # Use grunt server (require grunt serve command)
      proxy_pass http://localhost:9001;

      # OR serve static files directly :
      # charset utf-8;
      # root /path/to/docdoku-web-front/dist;
      # expires 0d;
      # access_log off;


      # Webservices REST
      location /api
      proxy_pass http://localhost:8080;


      # Websocket application
      location /ws
      proxy_pass http://localhost:8080/ws;
      proxy_http_version 1.1;
      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection "upgrade";
      proxy_read_timeout 7200s;








      nginx






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Apr 25 at 5:51







      Shihe Zhang

















      asked Apr 25 at 2:02









      Shihe ZhangShihe Zhang

      1036




      1036




















          1 Answer
          1






          active

          oldest

          votes


















          0














          Since it's a separated back-end and front-end project, and can be visit success locally.

          So the back-end is correctly config.
          The failed request



          Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers


          So it's not looking into the right domain. Since the machine A's IP is 192.168.1.164, so the right request URL domain should be there.

          It's where the front-end should request, and it's not related with the nginx config file.

          Finally, find out there is a config file for the front-end, there's a part config the server domain, which was localhost. After change it to 192.168.1.164 it worked.

          No matter what it is, any separated front-end and back-end project should have somewhere for front-end to connect the back-end.



          My wonder was since the front-end was deployed on the same server of the back-end, the localhost should work. After I inspect some website, find most of them use a public domain name, like somewebsite.com rather than localhost, though they may not deployed on the same server, this inspired me. Guess there should some kind of front-end client, maybe from the source of the inspect , which need to connect the real back-end.



          Really lack of the front-end knowledge, correction is welcome if there are any mistake.






          share|improve this answer























            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%2f964493%2fcant-visit-service-other-than-server-machine-a-seperated-backend-and-frontend%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            Since it's a separated back-end and front-end project, and can be visit success locally.

            So the back-end is correctly config.
            The failed request



            Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers


            So it's not looking into the right domain. Since the machine A's IP is 192.168.1.164, so the right request URL domain should be there.

            It's where the front-end should request, and it's not related with the nginx config file.

            Finally, find out there is a config file for the front-end, there's a part config the server domain, which was localhost. After change it to 192.168.1.164 it worked.

            No matter what it is, any separated front-end and back-end project should have somewhere for front-end to connect the back-end.



            My wonder was since the front-end was deployed on the same server of the back-end, the localhost should work. After I inspect some website, find most of them use a public domain name, like somewebsite.com rather than localhost, though they may not deployed on the same server, this inspired me. Guess there should some kind of front-end client, maybe from the source of the inspect , which need to connect the real back-end.



            Really lack of the front-end knowledge, correction is welcome if there are any mistake.






            share|improve this answer



























              0














              Since it's a separated back-end and front-end project, and can be visit success locally.

              So the back-end is correctly config.
              The failed request



              Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers


              So it's not looking into the right domain. Since the machine A's IP is 192.168.1.164, so the right request URL domain should be there.

              It's where the front-end should request, and it's not related with the nginx config file.

              Finally, find out there is a config file for the front-end, there's a part config the server domain, which was localhost. After change it to 192.168.1.164 it worked.

              No matter what it is, any separated front-end and back-end project should have somewhere for front-end to connect the back-end.



              My wonder was since the front-end was deployed on the same server of the back-end, the localhost should work. After I inspect some website, find most of them use a public domain name, like somewebsite.com rather than localhost, though they may not deployed on the same server, this inspired me. Guess there should some kind of front-end client, maybe from the source of the inspect , which need to connect the real back-end.



              Really lack of the front-end knowledge, correction is welcome if there are any mistake.






              share|improve this answer

























                0












                0








                0







                Since it's a separated back-end and front-end project, and can be visit success locally.

                So the back-end is correctly config.
                The failed request



                Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers


                So it's not looking into the right domain. Since the machine A's IP is 192.168.1.164, so the right request URL domain should be there.

                It's where the front-end should request, and it's not related with the nginx config file.

                Finally, find out there is a config file for the front-end, there's a part config the server domain, which was localhost. After change it to 192.168.1.164 it worked.

                No matter what it is, any separated front-end and back-end project should have somewhere for front-end to connect the back-end.



                My wonder was since the front-end was deployed on the same server of the back-end, the localhost should work. After I inspect some website, find most of them use a public domain name, like somewebsite.com rather than localhost, though they may not deployed on the same server, this inspired me. Guess there should some kind of front-end client, maybe from the source of the inspect , which need to connect the real back-end.



                Really lack of the front-end knowledge, correction is welcome if there are any mistake.






                share|improve this answer













                Since it's a separated back-end and front-end project, and can be visit success locally.

                So the back-end is correctly config.
                The failed request



                Request URL: http://localhost:8080/eplmp-server-rest/api/auth/providers


                So it's not looking into the right domain. Since the machine A's IP is 192.168.1.164, so the right request URL domain should be there.

                It's where the front-end should request, and it's not related with the nginx config file.

                Finally, find out there is a config file for the front-end, there's a part config the server domain, which was localhost. After change it to 192.168.1.164 it worked.

                No matter what it is, any separated front-end and back-end project should have somewhere for front-end to connect the back-end.



                My wonder was since the front-end was deployed on the same server of the back-end, the localhost should work. After I inspect some website, find most of them use a public domain name, like somewebsite.com rather than localhost, though they may not deployed on the same server, this inspired me. Guess there should some kind of front-end client, maybe from the source of the inspect , which need to connect the real back-end.



                Really lack of the front-end knowledge, correction is welcome if there are any mistake.







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Apr 25 at 13:10









                Shihe ZhangShihe Zhang

                1036




                1036



























                    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%2f964493%2fcant-visit-service-other-than-server-machine-a-seperated-backend-and-frontend%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

                    Wikipedia:Vital articles Мазмуну Biography - Өмүр баян Philosophy and psychology - Философия жана психология Religion - Дин Social sciences - Коомдук илимдер Language and literature - Тил жана адабият Science - Илим Technology - Технология Arts and recreation - Искусство жана эс алуу History and geography - Тарых жана география Навигация менюсу

                    Bruxelas-Capital Índice Historia | Composición | Situación lingüística | Clima | Cidades irmandadas | Notas | Véxase tamén | Menú de navegacióneO uso das linguas en Bruxelas e a situación do neerlandés"Rexión de Bruxelas Capital"o orixinalSitio da rexiónPáxina de Bruselas no sitio da Oficina de Promoción Turística de Valonia e BruxelasMapa Interactivo da Rexión de Bruxelas-CapitaleeWorldCat332144929079854441105155190212ID28008674080552-90000 0001 0666 3698n94104302ID540940339365017018237

                    What should I write in an apology letter, since I have decided not to join a company after accepting an offer letterShould I keep looking after accepting a job offer?What should I do when I've been verbally told I would get an offer letter, but still haven't gotten one after 4 weeks?Do I accept an offer from a company that I am not likely to join?New job hasn't confirmed starting date and I want to give current employer as much notice as possibleHow should I address my manager in my resignation letter?HR delayed background verification, now jobless as resignedNo email communication after accepting a formal written offer. How should I phrase the call?What should I do if after receiving a verbal offer letter I am informed that my written job offer is put on hold due to some internal issues?Should I inform the current employer that I am about to resign within 1-2 weeks since I have signed the offer letter and waiting for visa?What company will do, if I send their offer letter to another company