Java AWS Server: 502 Bad Gateway nginx/1.8.1

主宰稳场 提交于 2019-12-01 01:04:30

When you select Java , as a container then your jar should be an executable jar. i.e if you run using jar command from your console it should fail there as well.

what you should do to resolve it build it using plugin
e.g

<build>
    <plugins>
        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>

        </plugin>
    </plugins>

</build>

this will solve the no manifest in jar issue , you can verify by 1. running jar from command propmpt or 2. open jar in winrar or something and see the content of maifest.mf file

the ngix issue is different

Today I solved a similar problem. I had the same error (502 Bad Gateway nginx/1.8.1) when trying to run NodeJS+Docker server app on Elastic Beanstalk. The mistake was in wrong selection of platform type (NodeJS instead of Docker) during creating of environment.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!