map $http_upgrade $connection_upgrade {
  default upgrade;
  '' close;
}

server {
        listen 80 default_server;
        listen [::]:80 default_server;
        root /var/www/html/dist;

        # reverse proxy
        location /interaction {
            proxy_pass                         http://environment-24-163.seec.svc.cluster.local:8080;
        }

        location ~ /api {
      	    proxy_pass http://environment-24-163.seec.svc.cluster.local:8080;
      	    proxy_set_header Host             $host;
      	    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      	    proxy_set_header X-Forwarded-Proto $scheme;
      	    proxy_set_header X-Forwarded-Port $server_port;
  	}
        location ~ / {
            try_files $uri $uri/ /index.html;
        }
}

http {
        client_max_body_size 1024M;
}
