From ae6cc32ed5693dba41e12ba6527b00c7845bc78b Mon Sep 17 00:00:00 2001 From: mur-dog Date: Fri, 27 Feb 2015 16:12:09 -0700 Subject: [PATCH 1/3] Allow Proxy Request agent to be turned off --- lib/ionic/serve.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/ionic/serve.js b/lib/ionic/serve.js index 237f2a63d0..56d0ca6f9d 100644 --- a/lib/ionic/serve.js +++ b/lib/ionic/serve.js @@ -204,7 +204,11 @@ IonicTask.prototype.start = function(ionic) { for(var x=0; x " + url.format(proxy.proxyUrl)); } } From ce0ee79f66e33abd9e5c3145dda56a05e4a4f0fd Mon Sep 17 00:00:00 2001 From: mur-dog Date: Fri, 27 Feb 2015 16:20:30 -0700 Subject: [PATCH 2/3] Allow Proxy Request agent to be turned off --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index a41944a5e5..41788102d4 100644 --- a/README.md +++ b/README.md @@ -226,10 +226,11 @@ __Service Proxies:__ The `serve` command can add some proxies to the http server. These proxies are useful if you are developing in the browser and you need to make calls to an external API. With this feature you can proxy request to the external api through the ionic http server preventing the `No 'Access-Control-Allow-Origin' header is present on the requested resource` error. -In the `ionic.project` file you can add a property with an array of proxies you want to add. The proxies are object with two properties: +In the `ionic.project` file you can add a property with an array of proxies you want to add. The proxies are object with the following properties: * `path`: string that will be matched against the beginning of the incoming request URL. * `proxyUrl`: a string with the url of where the proxied request should go. +* `proxyNoAgent` (optional): true/false, if true the connection to the proxy server will not use keep-alives and the default connection pooling of HttpAgent ```json { From f4d99aa43b7a11c2d9dcd24b1dafa856ddef65e6 Mon Sep 17 00:00:00 2001 From: mur-dog Date: Fri, 27 Feb 2015 16:26:00 -0700 Subject: [PATCH 3/3] updated description --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 41788102d4..6ddca0275a 100644 --- a/README.md +++ b/README.md @@ -230,7 +230,7 @@ In the `ionic.project` file you can add a property with an array of proxies you * `path`: string that will be matched against the beginning of the incoming request URL. * `proxyUrl`: a string with the url of where the proxied request should go. -* `proxyNoAgent` (optional): true/false, if true the connection to the proxy server will not use keep-alives and the default connection pooling of HttpAgent +* `proxyNoAgent`: (optional) true/false, if true opts out of connection pooling, see [HttpAgent](http://nodejs.org/api/http.html#http_class_http_agent) ```json {