Configure network proxy
Usage of network proxy
If your computer is behind a network proxy, you might use a proxy configuration for some of the grunt tasks in devtools.
Local http server
The local http server forwards request (for not locally available resources) to the configured remoteUrl. Configure a proxy if the remoteUrl can be reached through your network proxy only.
Upload of the webpackages
Uploading a webpackage to a remote Cubbles Base requires access to the Base instance. Configure a proxy if the Base instance can be reached through your network proxy only.
Configure the network proxy as environment variables
Use the environment variables http_proxy
, https_proxy
and no_proxy (or HTTP_PROXY
, HTTPS_PROXY
and NO_PROXY
) to configure a network proxy for your local environment.
Configure the network proxy in linux
$ export http_proxy=http://my-http-proxy:80 $ export https_proxy=https://my-https-proxy:443 $ export no_proxy=localhost,127.0.0.1
Configure the network proxy in windows
- Type
Win+Pause
to open theAdvanced system settings
- Open
Environment Variables
- Add a new environment variable
http_proxy
, and configure the http proxy url - Add a new environment variable
https_proxy
, and configure the https proxy url - Add a new environment variable
no_proxy
if you will exclude domains from proxy, and configure a comma separeted list of excludes.
Configure the network proxy for the workspace
If you won't configure the network proxy in the enviroment, you can config it in the .workspace
file. (<your project path>/webpackages/.workspace). The proxy configuration in .workspace
ovrride the enviroment variables.
{ "activeWebpackage": "my-demo-webpackage", "remoteStoreUrl": "https://cubbles.world/core-test", "http_proxy": "http://my-http-proxy:80", "https_proxy": "https://my-https-proxy:443" }
Configure the network proxy for a particular upload config
You can define proxy settings on upload config level using the proxy
property. For this particular upload config it overrides the existing higher-level configurations (in .workspace
or on you local machine).
{ "uploadConfigs": { "development": { "url": "http://cubbles-base-local/core-test", "proxy": "" } "release": { "url": "https://cubbles.world/core-test", "proxy": "https://my-proxy:443" } } }