Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

swagger-ui.min.js and jquery1.8.0.min.js fail to load on AWS Lambda using Sprint Boot 2 #3289

Closed
thomashoef opened this issue Apr 21, 2020 · 2 comments
Labels
Milestone

Comments

@thomashoef
Copy link

Version

2.6.1

Problem

I have deployed spring boot 2 lambda function on AWS using the aws serverless container and added auto swagger generation and swagger ui to the project. Locally, the swagger-ui.html is correctly generated and populated. Remotely, on AWS the content of /v2/api-docs is perfectly fine, but the swagger-ui.html file renders blank (without the content of my API).

I have noticed that there is an HTTP 502 error on serving
api-url/webjars/springfox-swagger-ui/swagger-ui.min.js, the same goes for jquery.

Expected

I would expect the swagger-ui file to render just as it does locally, what could be the cause of this?

@thomashoef
Copy link
Author

Update:

After upgrading to 2.9.1, even more resources are not accessible:

image

This is my whitelist:

private static final String[] AUTH_WHITELIST = {
        // -- swagger ui
        "/swagger-resources/**",
        "/swagger-ui.html",
        "/v2/api-docs",
        "/webjars/**"
};

Thanks
Thomas

@dilipkrish
Copy link
Member

This should be fixed in 3.0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants