Sign inSign up

rollout/simple-proxy

By rollout

•Updated over 3 years ago

Image
0

10K+

rollout/simple-proxy repository overview

⁠A simple proxy for Cloudbees Feature Management SDKs

This proxy forwards Rox SDK requests to CB FM service It is useful in case servers or clients (that are using CB FM SDKs) do not have internet access, are behind a firewall, clients without CORS permissions, or if full control over network requests is needed

  • In order for the SDK to communicate with the proxy, you'll have to also configure the SDK, see Docs

⁠Features - environment variable

⁠PORT (default: 8080)

docker's (internal) http port

⁠HTTPS_PORT (default: 8090)

docker's (internal) https port

⁠DISABLE_HTTPS (default: false)

for https need to set a valid certificate file, and key file To disable https set this variable to true.

⁠CERTIFICATE (default: './ssl/server.cert')

certificate file location

⁠CERTIFICATE_KEY (default: './ssl/server.key')

certificate key file location

⁠USER (default: undefined)

basic authentication user (between the SDK and the proxy - see Docs how to set on SDK side)

  • in order to enable basic authentication both user and password need to be set
⁠PASSWORD (default undefined)

basic authentication password (between the SDK and the proxy - see Docs how to set on SDK side)

  • in order to enable basic authentication both user and password need to be set
⁠LOG_LEVEL (default: info)

the logs level to write see http-proxy-middleware docs, currently: 'debug' | 'info' | 'warn' | 'error' | 'silent'

⁠Run with docker

⁠Template

docker run -e PORT=<internal http port> -e HTTPS_PORT=<internal https port> -e USER=<basic auth user> -e PASSWORD=<basic auth password> -e CERTIFICATE=<path to certification file> -e CERTIFICATE_KEY=<path to certification key file> -v <local path>:<docker path> -p:<external http port>:<internal http port> -p:<external https port>:<internal https port> -d rollout/simple-proxy

⁠Examples
⁠run with default env variables (only http on port 80)

docker run -p:80:8080 -d rollout/simple-proxy

⁠run with different internal http port, and use https (assuming certificate files exists on ~/localPath):

docker run -e PORT=9000 -e HTTPS_PORT=9090 -v ~/localPath:/dockerInternalPath -p:80:9000 -p:443:9090 -d rollout/simple-proxy

⁠run with different internal http port, and use https (assuming certificate files exists on ~/localPath), use basic authentication (user/password):

docker run -e PORT=9000 -e HTTPS_PORT=9090 -e USER=username -e PASSWORD=somePassword -e CERTIFICATE=/usr/src/app/mySsl/ser.cert -e CERTIFICATE_KEY=/usr/src/app/mySsl/ser.key -v ~/localPath:/usr/src/app/mySsl -p:80:9000 -p:443:9090 -d rollout/simple-proxy

Tag summary

Content type

Image

Digest

sha256:20d87aa66…

Size

43.6 MB

Last updated

over 3 years ago

docker pull rollout/simple-proxy