[英]Deploying .net core 2.1 on AWS ec2
Firstly I am new to aws and need some help. 首先,我是aws的新手,需要一些帮助。
I am trying to deploy an .net core 2.1 angular 6 web site to an ec2 instance. 我正在尝试将.net core 2.1 angular 6网站部署到ec2实例。
I have copied the code to the server and build it using the powershell console. 我已将代码复制到服务器并使用Powershell控制台进行构建。
I have tested the site using dotnet run and the site runs on https://localhost:5001/ . 我已经使用dotnet run测试了该站点,并且该站点在https:// localhost:5001 /上运行 。
The security group in AWS has the following inbound port ranges open: AWS中的安全组打开了以下入站端口范围:
1. 80 -> 0.0.0.0/0 (HTTP)
2. 443 -> 0.0.0.0/0 (HTTPS)
My question is, what do I need to do to expose this site to the outside world? 我的问题是,我需要怎么做才能将该网站暴露给外界?
If you do not wish to add a loadbalancer, the only thing you need to do is add an additional security group rule to allow port 5001 to be accessed by 0.0.0.0/0. 如果您不希望添加负载均衡器,则唯一需要做的就是添加一条附加的安全组规则,以允许0.0.0.0/0访问端口5001。 Might be a bit nicer if your application simply runs on port 80. 如果您的应用程序仅在端口80上运行,可能会更好一些。
If you wish to use a loadbalancer, checkout some of the AWS tutorials about it. 如果您想使用负载均衡器,请查看有关它的一些AWS教程 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.