WebFaction
Community site: login faq

We have a dedicated IP (184.172.xxx.yyy) but when I check, our server accesses the net (either with CURL or whatever) with the request originates from IP 184.172.zzz.xxx (which is our given IP). Is there anyway to correct this behavior?

asked 21 Jun '11, 14:31

brye
11
accept rate: 0%


For curl, you can use the --interface option to define the outgoing IP address. If you are using curl within PHP, for example, you can use something like this:

url_setopt($curlh, CURLOPT_INTERFACE, "xxx.xxx.xxx.xxx");

As far as I am aware, there is no way to set the "default" external interface for all outgoing requests. The software itself generally must support the operation.

permanent link

answered 21 Jun '11, 19:37

ryans ♦♦
5.0k93360
accept rate: 43%

edited 22 Jun '11, 03:38

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×23
×6

question asked: 21 Jun '11, 14:31

question was seen: 2,394 times

last updated: 22 Jun '11, 03:38

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM