Skip to main content

Installation

We provide the proxy in a few formats for usage:

  • Raw Source (Go)
  • Docker Image
  • OS Packaged Binary

The raw source can be used if needing to integrate a custom docker image; or if you need to build a custom binary for your environment that will use the exposed API to instanitate the proxy.

We recommend using the OS packaged version for easy future upgrades and management.

Deployment

Debian based

sudo dpkg -i devcycle-local-bucketing-proxy_*.deb
sudo apt-get install -f

RPM based

sudo rpm -i devcycle-local-bucketing-proxy_*.rpm

Configuration

A sample config.json file is included in the package and can be found at /etc/devcycle-local-bucketing-proxy/config.json.example. The most current version of the file can be found on our GitHub.

Alternatively - it can be configured via environment variables. The following environment variables are supported:

Environment Variables

DVC_LB_PROXY_SDK_KEY is the only required environment variable if not using a configuration file

KEYTYPEDEFAULTDESCRIPTION
DVC_LB_PROXY_CONFIGStringThe path to a JSON configuration file.
DVC_LB_PROXY_UNIX_SOCKET_PATHStringThe path to the Unix socket.
DVC_LB_PROXY_HTTP_PORTInteger8080The port to listen on for HTTP requests. Defaults to 8080.
DVC_LB_PROXY_UNIX_SOCKET_ENABLEDTrue or FalsefalseWhether to enable the Unix socket. Defaults to false.
DVC_LB_PROXY_HTTP_ENABLEDTrue or FalsetrueWhether to enable the HTTP server. Defaults to true.
DVC_LB_PROXY_SDK_KEYStringThe Server SDK key to use for this instance.
DVC_LB_PROXY_PLATFORMDATA_SDKTYPEStringInternal variable, setting a value other than default is not recommended.
DVC_LB_PROXY_PLATFORMDATA_SDKVERSIONStringInternal variable, setting a value other than default is not recommended.
DVC_LB_PROXY_PLATFORMDATA_PLATFORMVERSIONStringInternal variable, setting a value other than default is not recommended.
DVC_LB_PROXY_PLATFORMDATA_DEVICEMODELStringInternal variable, setting a value other than default is not recommended.
DVC_LB_PROXY_PLATFORMDATA_PLATFORMStringInternal variable, setting a value other than default is not recommended.
DVC_LB_PROXY_PLATFORMDATA_HOSTNAMEStringInternal variable, setting a value other than default is not recommended.
DVC_LB_PROXY_SDKCONFIG_EVENT_FLUSH_INTERVAL_MSDurationThe interval at which events are flushed to the events api in milliseconds.
DVC_LB_PROXY_SDKCONFIG_CONFIG_POLLING_INTERVAL_MSDurationThe interval at which the SDK polls the config CDN for updates in milliseconds.
DVC_LB_PROXY_SDKCONFIG_REQUEST_TIMEOUTDurationThe timeout for requests to the config CDN and events API in milliseconds.
DVC_LB_PROXY_SDKCONFIG_DISABLE_AUTOMATIC_EVENT_LOGGINGTrue or FalsefalseWhether to disable automatic event logging. Defaults to false.
DVC_LB_PROXY_SDKCONFIG_DISABLE_CUSTOM_EVENT_LOGGINGTrue or FalsefalseWhether to disable custom event logging. Defaults to false.
DVC_LB_PROXY_SDKCONFIG_MAX_EVENT_QUEUE_SIZEIntegerThe maximum number of events to be in the queue before dropping events.
DVC_LB_PROXY_SDKCONFIG_FLUSH_EVENT_QUEUE_SIZEIntegerThe minimum number of events to be in the queue before flushing events.
DVC_LB_PROXY_SDKCONFIG_CONFIG_CDN_URIStringThe URI of the Config CDN - leave unspecified if not needing an outbound proxy.
DVC_LB_PROXY_SDKCONFIG_EVENTSAPIURIStringThe URI of the Events API - leave unspecified if not needing an outbound proxy.

Post-Installation

If you have installed an OS packaged version of the proxy - the binary will be installed to /usr/bin/devcycle-local-bucketing-proxy.

You will need to configure a separate supervisor/orchestrator such as systemd or upstart if no you need to create a long-lived process.

We recommend keeping the logging output of the proxy available as it streams to stdout and stderr by default. To enable debug http logging, set the GIN_MODE environment variable to debug.