amazon-web-services - beego running on AWS 发行

标签 amazon-web-services amazon-ec2 go beego

我曾尝试在 AWS 上运行 Beego,但无论我尝试过什么,我似乎都无法连接到运行 Beego 的端口 8080。我不确定这是 AWS 还是 Beego 的问题,但我似乎也无法连接到端口 80(我尝试更改安全组设置,包括添加一个新的以允许访问两个端口)。但是,当我 curl 127.0.0.1 时,有一个 Beego 模板,但是 my E2 instance 什么也没有。 .我将 app.conf 文件的 httpaddr 更改为 0.0.0.0,但这似乎没什么用。我该如何解决这个问题?

最佳答案

查你conf/app.conf文件:

httpaddr = localhost

默认情况下,beego 可以配置为仅监听本地主机(如 stated in this answer )。

Other issues包括(对于 AWS 部分):

  • 配置安全组以允许端口 8080 上的入站访问。
  • 是否为该端口禁用了任何应用程序防火墙,例如 Windows 防火墙或 Iptables?
  • 检查 netstat -anp|grep 80sudo iptables -L

对于 ubuntu,OP dtrinh100提及 in the comments必须:

get it to work by disabling iptables, but since I'm running Ubuntu, it was a little different.
I used the iptables command from "How to start/stop iptables on Ubuntu?", which allowed me to turn off iptables in Ubuntu.

关于amazon-web-services - beego running on AWS 发行,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25820721/

相关文章:

linux - 自动化 Amazon EBS 快照 任何人在 linux 上都有一个好的脚本或解决方案

go - 修改 interface{} golang 数组

database - 使用 go 和 InstantClient 从存储过程访问 OUT 参数(t_cursor 类型)

amazon-ec2 - 将 Hyper V 转换为 EC2

json - 覆盖 json.Marshal 使用的布局来格式化 time.Time

amazon-web-services - 使用 boto3 在 S3 中生成签名 URL

amazon-web-services - AWS EMR : Enable auto-termination-policy in cloudformation

amazon-web-services - 将公共(public) api 网关限制为特定 IP

git - 尝试使用 aws 命令获取部署组下的 ec2 实例列表

java - 在 EC2 实例 Ubuntu rabbitmq 上使用 RabbitMQ 线程 "main"java.net.UnknownHostException 中的异常