sifyfy / docker-rp

Home Page:https://hub.docker.com/r/sifyfy/rp

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

rp

A simple HTTP reverse proxy server for web development.

Usage

Simple:

docker --rm -it --network host sifyfy/rp -- -r /path/to:http://localhost:3000/path/to

Multiple settings:

docker --rm -it --network host sifyfy/rp -- \
    -r /foo:http://localhost:3000/foo \
    -r /bar:http://localhost:3001/bar

Use a config file

You can use a config file instead of specified settings to arguments.

(1) ./conf.yaml

reverse_proxy:
  - path: /foo
    url: http://localhost:3000/foo
  - path: /bar
    url: http://localhost:3001/bar

(2) run

docker --rm -it --network host -v $PWD/conf.yaml:/conf/conf.yaml sifyfy/rp

Build

Build docker image

git clone https://github.com/sifyfy/docker-rp.git
cd docker-rp
make

Build the generating nginx conf command

Requirements: Rust 1.30+ (Recommend latest stable)

git clone https://github.com/sifyfy/docker-rp.git
cd docker-rp
cargo build

or install generate-simple-reverse-proxy-conf-to-nginx

cargo install --git https://github.com/sifyfy/docker-rp.git

About

https://hub.docker.com/r/sifyfy/rp

License:Apache License 2.0


Languages

Language:Rust 96.1%Language:Dockerfile 3.5%Language:Makefile 0.4%