Warning
Work In Progress
The reverseproxy spawns for each connecting client a docker container and establishes the connection between client and server (in this case docker container).
Assuming you are using a Linux distribution (might or might not work on other Operating Systems).
- Download this repo:
git clone https://github.com/bekiralti/reverseproxy cd reverseproxy - Create
venv:python -m venv .venv source .venv/bin/activate
- Install:
or if you want to edit the source files (e.g.
pip install .src/reverseproxy/reverseproxy.py) and see its effects immediately:pip install -e .
- Create
server.pydocker container:Explanation:docker build -t server -f dockerfiles/server.dockerfile .serveris the dockername, it has to be the same as spawned insrc/reverseproxy/reverseproxy.py(see above)..is the context. - Run the UI (as of now only TUI):
python src/tui/tui.py
- Open another Terminal, make sure you are inside the repository directory and start the client example:
Optional: Start as many clients as you like.
python examples/client.py
- Have fun :) - Try sending messages from within each Client. - Try sending messages from the servers (in this case you have to use the TUI for this) to the clients. - Try closing some clients, sending messages, opening more clients, sending messages and so on :)
It is designed in such a way that the core src/reverseproxy/reverseproxy.py can run on its own. It is not dependent from the UI. It is not dependent from the docker container. This means you can fully provide your own UI implementation and docker container.
Further explanations coming soon.