Assets don't load (HTTP 503) with ShinyProxy behind AWS Load Balancer


I’m running ShinyProxy behind an AWS application load balancer, which takes care of the HTTPS stuff while ShinyProxy just serves HTTP requests. When I open an app in the browser, some assets (CSS, JavaScript, images) don’t load and the page looks broken. The browser’s developer console shows that all these HTTP requests got a 503 response. When I click on the resource URLs that failed to load as part of the app they load fine in isolation.

The weird thing is that some assets do load and it’s not always the same that fail or succeed to load. But most times most assets fail and the app is never fully functional.

GET https://xxx/endpoint/fa9f9ec3-37d3-4013-a254-1d2d8b450dfc/shared/bootstrap/css/bootstrap.min.css net::ERR_ABORTED 503

There is a GitHub issue that describes the same behaviour:

If I change the load balancer to a “Classic Load Balancer” (which doesn’t support websockets), all assets load fine every time - except that the websockets connection fails. So there must be something specific about handling requests from the application load balancer that breaks things in undertow.

Also, it seems that this issue arose when the Shiny app became more complex and had to load more assets.

Has anyone solved this and/or could help me troubleshoot this?


Not sure if related but it looks like a reverse proxy issue to me. My suggestion is to look at

The configuration of your aws should be similar to that in the Nginx config file.