4

I have developed an app using Spark Java Framework (www.sparkjava.com). I am able to build the artifact on my windows as a JAR file. I can confirm I am able to run it via command line "java -jar App.jar Main.java". It hosts a web app at localhost:4567.

What's the most convenient/quickest way to load this onto an AWS server? I created an EC2 instance (AMI Instance), copied over the jar file to it, ran the command. The log seems to run successfully, but I can't hit the DNS server. It doesn't seem to be up.

4

1 回答 1

2

我找到了解决方案。

  1. 登录 AWS
  2. 单击实例,然后单击您的实例
  3. 在描述中,请参阅安全组,单击您的安全组
  4. 在入站选项卡中,单击添加规则
  5. 添加 HTTP、HTTPS 和自定义
  6. 对于自定义,将端口设置为您希望对所有传入流量可用的端口。点击应用。
于 2015-12-17T21:03:15.277 回答