Initial Commit, Everything is working fine

This commit is contained in:
Christian Risi
2024-11-19 20:53:55 +01:00
parent 3268f8186d
commit b0a765aff7
7 changed files with 154 additions and 0 deletions

33
nginx/proxy.conf Normal file
View File

@@ -0,0 +1,33 @@
http {
# Leader-Service-Proxy
server {
# TODO: Change IP to a well defined one
listen *:80; # This is for testing purposes ONLY, to be changed to 443
server_name "nginx-mediator.internal";
location / {
proxy_pass "http://leader-service.internal";
proxy_pass_request_headers on;
proxy_pass_request_body on;
proxy_set_header X-Forwarded-For $sent_http_x_iot_ip; # X-IoT-IP
}
}
# IoT-Simulator Proxy
server {
listen *:80; # This is for testing purposes ONLY, to be changed to 443
location / {
proxy_pass "http://iot-simulator.internal";
proxy_pass_request_headers on;
proxy_pass_request_body on;
proxy_set_header X-Forwarded-Host $sent_http_x_iot_ip; # Set forwarded host to keep the original IP request
}
}
}