* all-in-one Dockerfile preparations * some cleanup * add to main pom and add links in index.html * updated deploy script from build pipeline * additional line feed just in case
141 lines
3.4 KiB
Nginx Configuration File
141 lines
3.4 KiB
Nginx Configuration File
error_log /tmp/error.log;
|
|
pid /tmp/nginx.pid;
|
|
|
|
worker_processes 1;
|
|
|
|
events { worker_connections 1024; }
|
|
|
|
http {
|
|
|
|
client_body_temp_path /tmp/client_body;
|
|
fastcgi_temp_path /tmp/fastcgi_temp;
|
|
proxy_temp_path /tmp/proxy_temp;
|
|
scgi_temp_path /tmp/scgi_temp;
|
|
uwsgi_temp_path /tmp/uwsgi_temp;
|
|
|
|
sendfile on;
|
|
|
|
upstream docker-webgoat {
|
|
server 127.0.0.1:8080;
|
|
}
|
|
|
|
upstream docker-webwolf {
|
|
server 127.0.0.1:9090;
|
|
}
|
|
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_set_header X-Forwarded-Host $server_name;
|
|
|
|
server {
|
|
listen 8888;
|
|
server_name www.webgoat.local;
|
|
|
|
root /var/www;
|
|
|
|
access_log /tmp/goataccess.log;
|
|
error_log /tmp/goaterror.log;
|
|
|
|
location ~* \.(png|jpg|jpeg|gif|ico|woff|otf|ttf|mvc|svg|txt|pdf|docx?|xlsx?)$ {
|
|
access_log off;
|
|
proxy_pass http://docker-webgoat;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location / {
|
|
root /usr/share/nginx/html;
|
|
index index.html;
|
|
add_header Cache-Control no-cache;
|
|
expires 0;
|
|
}
|
|
|
|
location /WebGoat {
|
|
proxy_pass http://docker-webgoat;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
}
|
|
|
|
server {
|
|
listen 8888;
|
|
server_name www.webwolf.local;
|
|
|
|
root /var/www;
|
|
|
|
access_log /tmp/wolfaccess.log;
|
|
error_log /tmp/wolferror.log;
|
|
|
|
location /WebGoat/PasswordReset/ForgotPassword/create-password-reset-link {
|
|
proxy_pass http://docker-webgoat;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /PasswordReset/reset/reset-password {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /files {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /tmpdir {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /webjars {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /css {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /login {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /images {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /mail {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /upload {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /js {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /landing {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /logout {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /WebWolf {
|
|
proxy_pass http://docker-webwolf;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
}
|
|
}
|