.NET项目的Elastic Beanstalk和CloudFormation有什么区别? [英] What is the difference between Elastic Beanstalk and CloudFormation for a .NET project?

查看:114
本文介绍了.NET项目的Elastic Beanstalk和CloudFormation有什么区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经开发了.NET MVC应用程序,并开始使用AWS并通过Visual Studio Toolkit进行部署。我已经使用工具箱中的Elastic Beanstalk选项成功部署了该应用程序。

I have developed a .NET MVC application and have started playing around with AWS and deploying it via the Visual Studio Toolkit. I have successfully deployed the application using the Elastic Beanstalk option in the toolkit.

在我学习如何使用工具箱将.NET应用程序部署到AWS的教程时,我注意到有一些使用 Elastic Beanstalk和CloudFormation 进行部署的教程。两者有什么区别?

As I was going over the tutorials for deploying .NET apps to AWS with the toolkit, I noticed there are tutorials for deploying with both Elastic Beanstalk and CloudFormation. What is the difference between these two?

据我所知,他们似乎基本上都在做同一件事-简化了将应用程序部署到AWS云的过程(设置EC2实例,负载平衡器,自动缩放等)。我尝试阅读它们两者,但是除了一堆对我来说听起来像是同一件事的时髦词汇外,我似乎什么也没得到。我什至在AWS网站上找到了常见问题解答,它应该回答这个确切的问题,但是我没有真的很明白。

From what I can tell, it seems like they both essentially are doing the same thing - making it easier to deploy your application to the AWS cloud (setting up EC2 instances, load balancer, auto-scaling, etc). I have tried reading up on them both, but I can't seem to get anything other than a bunch of buzz-words that sound like the same thing to me. I even found an FAQ on the AWS website that is supposed to answer this exact question, yet I don't really understand.

我应该使用其中一个吗?

Should I be using one or the other? Both?

推荐答案

它们实际上是完全不同的。 Elastic Beanstalk旨在使开发人员的生活更轻松。 CloudFormation旨在使系统工程师的生活更加轻松。

They're actually pretty different. Elastic Beanstalk is intended to make developers' lives easier. CloudFormation is intended to make systems engineers' lives easier.

Elastic Beanstalk是AWS IaaS服务之上的类似于PaaS的层,该层抽象了基础EC2实例,弹性负载均衡器。 ,自动缩放组等。这对于不想处理所有系统问题的开发人员而言,将其应用程序快速部署到AWS上要容易得多。它与其他PaaS产品(例如Heroku,EngineYard,Google App Engine等)非常相似。使用Elastic Beanstalk,您无需了解任何基础魔术的工作原理。

Elastic Beanstalk is a PaaS-like layer ontop of AWS's IaaS services which abstracts away the underlying EC2 instances, Elastic Load Balancers, auto scaling groups, etc. This makes it a lot easier for developers, who don't want to be dealing with all the systems stuff, to get their application quickly deployed on AWS. It's very similar to other PaaS products such as Heroku, EngineYard, Google App Engine, etc. With Elastic Beanstalk, you don't need to understand how any of the underlying magic works.

CloudFormation不会自动执行任何操作。这只是在巨大的JSON文件中定义部署所需的所有资源的一种方法。因此,CloudFormation模板实际上可能会创建两个ElasticBeanstalk环境(生产和暂存),几个ElasticCache集群,一个DyanmoDB表,然后在Route53中创建适当的DNS。然后,我将此模板上传到AWS,然后走开,然后45分钟后,一切准备就绪,正在等待。由于它只是纯文本JSON文件,因此我可以将其放在源代码管理中,这是对应用程序部署进行版本控制的好方法。它还可以确保我具有可重复的已知良好配置,可以快速将其部署在其他区域中。

CloudFormation, on the other hand, doesn't automatically do anything. It's simply a way to define all the resources needed for deployment in a huge JSON file. So a CloudFormation template might actually create two ElasticBeanstalk environments (production and staging), a couple of ElasticCache clusters, a DyanmoDB table, and then the proper DNS in Route53. I then upload this template to AWS, walk away, and 45 minutes later everything is ready and waiting. Since it's just a plain-text JSON file, I can stick it in my source control which provides a great way to version my application deployments. It also ensures that I have a repeatable, "known good" configuration that I can quickly deploy in a different region.

这篇关于.NET项目的Elastic Beanstalk和CloudFormation有什么区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆