简体   繁体   English

ECS Fargate定价

[英]ECS Fargate Pricing

I'd like to make sure I'm interpreting AWS's ECS Fargate pricing model correctly when compared to an m4.large EC2 instance (2vCPU, 8GB Mem) running non stop (even dropping to 1% cpu/mem utilization) for an entire month (730hrs). 与m4.large EC2实例(2vCPU,8GB Mem)运行不间断(甚至降至1%cpu / mem利用率)整整一个月相比,我想确保正确解释AWS的ECS Fargate定价模型(730hrs)。

# Monthly cost estimates

Fargate:
    cpu = 730hrs * 2vCPU * $0.056 = $73.88
    mem = 730hrs * 8GB Mem * $0.0127 = $74.17
    total = $73.88 + $74.17 = $148.05

EKS ec2 node (1 yr reserved no upfront):
    total = 730hrs * $0.062 = $45.26

EKS ec2 node (on demand):
    total = 730hrs * $0.10 = $73.00

It appears Fargate would be ~3x as expensive as an EC2 instance. 似乎Fargate的价格是EC2实例的3倍。 Does my Fargate pricing look accurate? 我的Fargate定价看起来准确吗? I'm assuming Fargate isn't intended to be used for something like a 24/7 website, but more like a one off job, analogous perhaps to a Lamba function that runs a container image. 我假设Fargate不打算用于像24/7网站这样的东西,但更像是一个一次性工作,可能类似于运行容器图像的Lamba函数。

Am I correct that I'm billed for the entire Fargate task cpu & mem allocation, regardless if I'm utilizing 1% or 100% of the resources? 我是否正确无论我是在使用1%还是100%的资源,我都会为整个Fargate任务cpu和内存分配付费?

References: 参考文献:

Your calculations seem correct to me. 你的计算对我来说似乎是对的。

I run a bunch of 24/7 websites as 0.25vCPU and 0.5GB RAM Fargate tasks just because of the ease of setting them up. 我运行一堆24/7网站作为0.25vCPU和0.5GB RAM Fargate任务只是因为它们易于设置。 They don't have lots of traffic and they are cached pretty heavily, but if they need to they can scale to 10x based on target CPU. 它们没有大量流量,并且它们的缓存非常大,但如果需要,它们可以根据目标CPU扩展到10倍。

Used that way I think they are pretty cost efficient. 使用这种方式我认为它们非常具有成本效益。

Update: AWS updated Fargate prices January 7, 2019. The prices now are $0.04048 per vCPU per hour and $0.004445 per GB memory per hour. 更新:AWS更新了Fargate价格2019年1月7日。现在价格为每小时每小时0.04048美元,每小时每GB内存0.004445美元。 Your example would now be: 你的例子现在是:

Fargate:
  cpu = 730hrs * 2vCPU * $0.04048 = $59.10
  mem = 730hrs * 8GB Mem * $0.004445 = $25.96
  total = $59.10 + $25.96 = $85.06

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM