6 changed files with 241 additions and 30 deletions
Unified View
Diff Options
-
20srv/conf/conf.d/portal.conf
-
40srv/conf/dnsmasq.conf
-
10srv/docker-compose.yml
-
195srv/nginx.airsas.conf
-
2srv/webapp/portal/index.html
-
4srv/webapp/portal/ready.html
@ -0,0 +1,195 @@ |
|||||
|
daemon off; |
||||
|
|
||||
|
worker_processes 1; |
||||
|
#Referes to single threaded process. Generally set to be equal to the number of CPUs or cores. |
||||
|
|
||||
|
#error_log logs/error.log; #error_log logs/error.log notice; |
||||
|
#Specifies the file where server logs. |
||||
|
|
||||
|
events { |
||||
|
worker_connections 1024; |
||||
|
# worker_processes and worker_connections allows you to calculate maxclients value: |
||||
|
# max_clients = worker_processes * worker_connections |
||||
|
} |
||||
|
|
||||
|
|
||||
|
http { |
||||
|
include mime.types; |
||||
|
# anything written in /opt/nginx/conf/mime.types is interpreted as if written inside the http { } block |
||||
|
|
||||
|
default_type application/octet-stream; |
||||
|
|
||||
|
#log_format main '$remote_addr - $remote_user [$time_local] "$request" ' |
||||
|
# '$status $body_bytes_sent "$http_referer" ' |
||||
|
# '"$http_user_agent" "$http_x_forwarded_for"'; |
||||
|
|
||||
|
#access_log logs/access.log main; |
||||
|
|
||||
|
sendfile on; |
||||
|
# If serving locally stored static files, sendfile is essential to speed up the server, |
||||
|
# But if using as reverse proxy one can deactivate it |
||||
|
|
||||
|
#tcp_nopush on; |
||||
|
# works opposite to tcp_nodelay. Instead of optimizing delays, it optimizes the amount of data sent at once. |
||||
|
|
||||
|
#keepalive_timeout 0; |
||||
|
keepalive_timeout 65; |
||||
|
# timeout during which a keep-alive client connection will stay open. |
||||
|
|
||||
|
gzip on; |
||||
|
# tells the server to use on-the-fly gzip compression. |
||||
|
|
||||
|
server { |
||||
|
# You would want to make a separate file with its own server block for each virtual domain |
||||
|
# on your server and then include them. |
||||
|
listen 80; |
||||
|
#tells Nginx the hostname and the TCP port where it should listen for HTTP connections. |
||||
|
|
||||
|
server_name localhost eca.aero ife.aero gom.aero; |
||||
|
# lets you doname-based virtual hosting |
||||
|
|
||||
|
#access_log logs/host.access.log; |
||||
|
|
||||
|
location /hotspot-detect.html { |
||||
|
proxy_set_header Host $host; |
||||
|
proxy_set_header X-Real-IP $remote_addr; |
||||
|
proxy_set_header X-Forwarded-For $remote_addr; |
||||
|
proxy_set_header X-Forwarded-Host $remote_addr; |
||||
|
proxy_pass http://localhost:8889; |
||||
|
} |
||||
|
|
||||
|
# Link to pxeasy |
||||
|
location /pxeasy/ { |
||||
|
proxy_pass http://localhost:23457; |
||||
|
} |
||||
|
|
||||
|
location /logging/ { |
||||
|
proxy_pass http://localhost:23457; |
||||
|
} |
||||
|
|
||||
|
location / { |
||||
|
proxy_set_header Host $host; |
||||
|
proxy_set_header X-Real-IP $remote_addr; |
||||
|
proxy_set_header X-Forwarded-For $remote_addr; |
||||
|
proxy_set_header X-Forwarded-Host $remote_addr; |
||||
|
if ($http_user_agent ~ "^CaptiveNetworkSupport(.*)$") { |
||||
|
proxy_pass http://172.19.0.1:8031; |
||||
|
} |
||||
|
|
||||
|
#The location setting lets you configure how nginx responds to requests for resources within the server. |
||||
|
root /var/www/html; |
||||
|
index index.html; |
||||
|
} |
||||
|
# Link to pxeasy |
||||
|
# location /pxeasy/ { |
||||
|
# proxy_pass http://localhost:23457; |
||||
|
# } |
||||
|
# location /logging/ { |
||||
|
# proxy_pass http://localhost:23457; |
||||
|
# } |
||||
|
|
||||
|
|
||||
|
#error_page 404 /404.html; |
||||
|
|
||||
|
# redirect server error pages to the static page /50x.html |
||||
|
# |
||||
|
#error_page 500 502 503 504 /50x.html; |
||||
|
#location = /50x.html { |
||||
|
# root html; |
||||
|
#} |
||||
|
|
||||
|
# proxy the PHP scripts to Apache listening on 127.0.0.1:80 |
||||
|
# |
||||
|
#location ~ \.php$ { |
||||
|
# proxy_pass http://127.0.0.1; |
||||
|
#} |
||||
|
} |
||||
|
# Default https |
||||
|
server { |
||||
|
listen 443; |
||||
|
ssl on; |
||||
|
ssl_certificate /etc/nginx/IFE_Cer.pem; |
||||
|
ssl_certificate_key /etc/nginx/IFE_Cer_key.pem; |
||||
|
location / { |
||||
|
root /var/www/html; |
||||
|
index index.html; |
||||
|
} |
||||
|
# PATCH waiting for certificate on pxeasy.ife.aero |
||||
|
location /pxeasy/ { |
||||
|
proxy_pass http://localhost:23457; |
||||
|
} |
||||
|
location /logging/ { |
||||
|
proxy_pass http://localhost:23457; |
||||
|
} |
||||
|
} |
||||
|
# PXEasy https |
||||
|
server { |
||||
|
listen 443; |
||||
|
server_name pxeasy.ife.aero; |
||||
|
ssl on; |
||||
|
ssl_certificate /etc/nginx/IFE_Cer.pem; |
||||
|
ssl_certificate_key /etc/nginx/IFE_Cer_key.pem; |
||||
|
location / { |
||||
|
proxy_pass http://localhost:23457; |
||||
|
} |
||||
|
} |
||||
|
# API to cabin crew server |
||||
|
server { |
||||
|
listen 443; |
||||
|
server_name api.ife.aero; |
||||
|
access_log api-https.access.log; |
||||
|
ssl on; |
||||
|
ssl_certificate /etc/nginx/IFE_Cer.pem; |
||||
|
ssl_certificate_key /etc/nginx/IFE_Cer_key.pem; |
||||
|
location /cabincrew/passengersannouncements/subscribe { |
||||
|
proxy_pass http://cabincrew-api:9001/cabincrew/passengersannouncements/subscribe; |
||||
|
proxy_http_version 1.1; |
||||
|
proxy_set_header Upgrade $http_upgrade; |
||||
|
proxy_set_header Connection "upgrade"; |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
server { |
||||
|
listen 80 default_server; |
||||
|
server_name _; |
||||
|
|
||||
|
location / { |
||||
|
proxy_set_header Host $host; |
||||
|
proxy_set_header X-Real-IP $remote_addr; |
||||
|
proxy_set_header X-Forwarded-For $remote_addr; |
||||
|
proxy_set_header X-Forwarded-Host $remote_addr; |
||||
|
proxy_pass http://172.19.0.1:8031; |
||||
|
} |
||||
|
|
||||
|
access_log captive-pxportal-access.log; |
||||
|
error_log captive-pxportal-error.log; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
# CAPTIVE PORTAL |
||||
|
# server { |
||||
|
# listen 80; |
||||
|
# server_name |
||||
|
# *.firefox.com |
||||
|
# *.ubuntu.com |
||||
|
# *.google.com |
||||
|
# *.android.com |
||||
|
# *.gstatic.com |
||||
|
# *.apple.com |
||||
|
# *.gnome.org |
||||
|
# captive.eca.aero; |
||||
|
|
||||
|
# location / { |
||||
|
# proxy_set_header Host $host; |
||||
|
# proxy_set_header X-Real-IP $remote_addr; |
||||
|
# proxy_set_header X-Forwarded-For $remote_addr; |
||||
|
# proxy_set_header X-Forwarded-Host $remote_addr; |
||||
|
# proxy_pass http://localhost:8889; |
||||
|
# } |
||||
|
|
||||
|
# access_log captive-portal-access.log; |
||||
|
# error_log captive-portal-error.log; |
||||
|
# } |
||||
|
|
||||
|
} |
||||
Write
Preview
Loading…
Cancel
Save