Using PCF Dev Behind a Proxy

Page last updated:

This topic describes how to use PCF Dev with a proxy.

Run PCF Dev Behind an HTTP Proxy

In a restricted network environment, configuring PCF Dev to connect to an HTTP proxy permits app-to-Internet connectivity, access to custom buildpacks, and the use of Docker images from the public Internet.

To run PCF Dev behind a proxy, set the standard proxy environment variables for your platform before you start PCF Dev:

Note: Proxy Support is not currently supported on Linux. That means the environment variables HTTP_PROXY, HTTPS_PROXY, NO_PROXY are not fully supported. Proxy Support on Linux is only supported in PCF Dev v0.30 or earlier.

  • Using Mac OS X:
    > cf dev start
  • Using Windows PowerShell:
    >> $env:HTTP_PROXY = "http://PROXY_IP:PROXY_PORT"
    >> $env:HTTPS_PROXY = "http://PROXY_IP:PROXY_PORT"
    >> cf dev start

Note: Do not use localhost for PROXY_IP or as the proxy server hostname, because localhost refers to the PCF Dev VM itself. If PCF Dev needs to use a locally-running HTTP proxy, the proxy must be listening on all network interfaces, and you must address it as For a system domain, address the proxy as, and so on.

Use the cf CLI Behind an HTTP Proxy

You must configure the cf CLI to bypass your HTTP proxy for addresses that end in, which is your system domain:

  • For Mac OS X:
    $ export,,$NO_PROXY
    $ cf login -a --skip-ssl-validation
  • For Windows PowerShell:
    >> $env:NO_PROXY = ",,OTHER-DOMAINS"
    >> cf login -a --skip-ssl-validation

Allow Application Traffic to Bypass the Proxy

You can configure your apps to connect to other addresses without using the proxy. For example, you can connect apps to user-provided services on a private network.

  • Set the NO_PROXY environment variable to a comma-separated list of hosts:
    $ cf set-env APP_NAME NO_PROXY=,