The python_webapp is useful for performing HTTP load-balancing tests to a cluster of nodes.
143
The python_webapp is useful for performing HTTP load-balancing tests to a cluster of nodes. For example, to test a kubernetes cluster. The web app displays a couple of outputs based on a simple Python Flask app:
Components version: python:3.10.5-slim-buster flask==2.1.2
*Flask listens on TCP Port 8080
Step 1: Docker run
docker run -it -p 5000:8080 petechua/python-webapp:1.0
Step 2: Run HTTP GET to python-webapp
Example
#######
curl --header "X-Forwarded-For: 192.168.0.2" http://172.16.1.71:5000
Output
######
Server DateTime:2022-07-06 09:55:16.842094
Server Hostname:2c03861afa63
Server IP:172.17.0.8
Client IP:172.16.1.208
Client IP(XFF):192.168.0.2
Content type
Image
Digest
Size
47.2 MB
Last updated
about 4 years ago
docker pull petechua/python-webapp:1.0