how to send requests with floating ip instead of actual ip linux











up vote
0
down vote

favorite
1












I am using Heztner server for running my application, which owns IP as 95.216.167.191. Then I added a floating Ip which was 159.69.100.75.



I added this floating IP to network settings as well as



nano /etc/network/interfaces.d/60-my-floating-ip.cfg


and pasted this



auto eth0:1
iface eth0:1 inet static
address 159.69.100.75
netmask 32


then restarted network as sudo service networking restart.



Even though now when I send a curl request to another system as



curl -X POST -F 'firstname=floating' -F 'lastname=iping' -F 'username=iamfloating' -F 'email=fffloating@email.com' -F 'password=floatingpass' -F 'token=web' https://media.evercam.io/v1/users


still, as a result of that request, my actual IP is being used.



[POST v1/users] [curl/7.47.0] [95.216.167.191] [fffloating@email.com] [fffloating@email.com] [web]


what I am doing wrong? the thing I want to achieve is, to send all the requests either its POST, PUT, GET or DELETE from floating IP, not the actual one.










share|improve this question




























    up vote
    0
    down vote

    favorite
    1












    I am using Heztner server for running my application, which owns IP as 95.216.167.191. Then I added a floating Ip which was 159.69.100.75.



    I added this floating IP to network settings as well as



    nano /etc/network/interfaces.d/60-my-floating-ip.cfg


    and pasted this



    auto eth0:1
    iface eth0:1 inet static
    address 159.69.100.75
    netmask 32


    then restarted network as sudo service networking restart.



    Even though now when I send a curl request to another system as



    curl -X POST -F 'firstname=floating' -F 'lastname=iping' -F 'username=iamfloating' -F 'email=fffloating@email.com' -F 'password=floatingpass' -F 'token=web' https://media.evercam.io/v1/users


    still, as a result of that request, my actual IP is being used.



    [POST v1/users] [curl/7.47.0] [95.216.167.191] [fffloating@email.com] [fffloating@email.com] [web]


    what I am doing wrong? the thing I want to achieve is, to send all the requests either its POST, PUT, GET or DELETE from floating IP, not the actual one.










    share|improve this question


























      up vote
      0
      down vote

      favorite
      1









      up vote
      0
      down vote

      favorite
      1






      1





      I am using Heztner server for running my application, which owns IP as 95.216.167.191. Then I added a floating Ip which was 159.69.100.75.



      I added this floating IP to network settings as well as



      nano /etc/network/interfaces.d/60-my-floating-ip.cfg


      and pasted this



      auto eth0:1
      iface eth0:1 inet static
      address 159.69.100.75
      netmask 32


      then restarted network as sudo service networking restart.



      Even though now when I send a curl request to another system as



      curl -X POST -F 'firstname=floating' -F 'lastname=iping' -F 'username=iamfloating' -F 'email=fffloating@email.com' -F 'password=floatingpass' -F 'token=web' https://media.evercam.io/v1/users


      still, as a result of that request, my actual IP is being used.



      [POST v1/users] [curl/7.47.0] [95.216.167.191] [fffloating@email.com] [fffloating@email.com] [web]


      what I am doing wrong? the thing I want to achieve is, to send all the requests either its POST, PUT, GET or DELETE from floating IP, not the actual one.










      share|improve this question















      I am using Heztner server for running my application, which owns IP as 95.216.167.191. Then I added a floating Ip which was 159.69.100.75.



      I added this floating IP to network settings as well as



      nano /etc/network/interfaces.d/60-my-floating-ip.cfg


      and pasted this



      auto eth0:1
      iface eth0:1 inet static
      address 159.69.100.75
      netmask 32


      then restarted network as sudo service networking restart.



      Even though now when I send a curl request to another system as



      curl -X POST -F 'firstname=floating' -F 'lastname=iping' -F 'username=iamfloating' -F 'email=fffloating@email.com' -F 'password=floatingpass' -F 'token=web' https://media.evercam.io/v1/users


      still, as a result of that request, my actual IP is being used.



      [POST v1/users] [curl/7.47.0] [95.216.167.191] [fffloating@email.com] [fffloating@email.com] [web]


      what I am doing wrong? the thing I want to achieve is, to send all the requests either its POST, PUT, GET or DELETE from floating IP, not the actual one.







      18.04 ip reverse-proxy






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Oct 16 at 7:31

























      asked Oct 16 at 6:13









      Junaid Farooq

      11318




      11318



























          active

          oldest

          votes











          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "89"
          };
          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',
          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%2faskubuntu.com%2fquestions%2f1084148%2fhow-to-send-requests-with-floating-ip-instead-of-actual-ip-linux%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown






























          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes
















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Ask Ubuntu!


          • 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.





          Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


          Please pay close attention to the following guidance:


          • 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%2faskubuntu.com%2fquestions%2f1084148%2fhow-to-send-requests-with-floating-ip-instead-of-actual-ip-linux%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

          Biblatex bibliography style without URLs when DOI exists (in Overleaf with Zotero bibliography)

          ComboBox Display Member on multiple fields

          Is it possible to collect Nectar points via Trainline?