Cloud Foundry,它是如何工作的?

Cloud Foundry, how it works?

据我了解,它不会为每个新服务创建一个虚拟机,但它会将 Warden 容器中的所有服务运行到 'DEA' 虚拟机中,位于 IaaS 提供商(如 Openstack, AWS..)

我不明白的是:DEA VM 'reserve' X 资源是否随时可用(即使没有部署任何服务)?在这种情况下,我将始终为最大资源付费。

另一个问题:如果 DEA 是 'full' 并且我也需要扩展它怎么办?可能吗?要即时创建另一个 DEA VM 并将一些服务移动到那里?我怎样才能找到关于它的一些文档?我发现 CloudFoundry 网站没有太多信息

As I understood, it does not create a Virtual Machine for every new service, but it runs all the services in a Warden container into the 'DEA' Virtual Machine, somewhere in a IaaS provider (like Openstack, AWS..)

如果把"service"这个词换成"app",这个说法是正确的。做出这种区分很重要,因为 Cloud Foundry 也有服务的概念,这与应用程序不同。

总而言之,Cloud Foundry 运行 有一个或多个 DEA VM。这些是在您的 IaaS 上配置的,通常使用 Bosh。您推送到 Cloud Foundry 的应用程序将 运行 在 DEA VM 中。在 DEA 上,应用程序将 运行 在容器中,容器将应用程序隔离。

What I didn't understood is: does the DEA VM 'reserve' X resources at any time (so even if there are no services deployed)?? In this case i would pay for the maximum resources always.

DEA VM 是在您部署 Cloud Foundry 时创建的。此时它们被分配了资源限制(RAM、VCPUS 等)。在不部署任何应用程序的情况下,DEA VM 上的 运行ning 并不多,但其中大部分资源未被使用。

当您或您的用户部署应用程序时,DEA 将为 运行 您的应用程序创建新容器。容器创建得非常非常快,因此不需要预先分配。此外,容器本身并不真正消耗资源,它们只是为其中的应用程序设置限制 运行ning。

是应用程序本身消耗了大量资源,例如磁盘 space、内存和 CPU。不过,只有当应用 运行ning 时才会发生这种情况。

Another question: what if the DEA is 'full' ?

如果有空间,Cloud Foundry 只会在 DEA 上部署应用程序。当一个填满时,它会停止使用新的应用程序。其他 DEA(如果有的话)将需要采用新应用,否则您的用户将收到一条错误消息,提示没有足够的空间安装新应用。

and I need to scale it too would be possible? To create on the fly another DEA VM and move some services there?

如果您使用 Bosh 进行部署,答案是肯定的。你可以告诉波什你想要部署多少 DEA,它会做到这一点。

How can I find some documentation about that? I find the CloudFoundry website don't have much information

我建议从 Bosh 文档开始。那些是 here. Then look at the "Running Cloud Foundry" column on the docs page here.

对于 OpenStack,您可以查看这些 instructions and if you have any questions the vcap-dev 邮件列表是询问他们的好地方。