-
Notifications
You must be signed in to change notification settings - Fork 123
Expand file tree
/
Copy pathoverview.html.md.erb
More file actions
249 lines (158 loc) · 12.5 KB
/
overview.html.md.erb
File metadata and controls
249 lines (158 loc) · 12.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
---
title: Cloud Foundry overview
---
<%# Reset page title based on product title %>
<% if vars.platform_code != 'CF' %>
<% set_title(vars.app_runtime_abbr, "Overview") %>
<% end %>
<% if vars.platform_code == 'CF' %>
This topic tells you about Cloud Foundry and how it works.
<% else %>
This topic tells you about <%= vars.app_runtime_first %> and how it works with <%= vars.ops_manager %>.
<% end %>
## Introduction to Cloud Platforms
Cloud platforms enable rapid deployment of applications and services, making them globally accessible within minutes. When application requests increase, cloud infrastructure can automatically scale to meet higher demand, eliminating traditional build-outs and migrations. This approach allows developers to focus on applications and data without the need to manage underlying infrastructure.
The following diagram illustrates the layers of a typical technology stack, comparing the traditional IT model with an IaaS stack and a PaaS stack, showing which layers are managed by users vs. providers.
* **Traditional IT Stack:** All layers are managed in-house, including applications, data, runtime, middleware, OS, virtualization, servers, storage, and networking.
* **IaaS Stack:** The provider manages the servers, storage, networking, and virtualization, while the user manages applications, data, runtime, middleware, and OS.
* **PaaS Stack:** The provider manages all layers except for applications and data, which remain the user’s responsibility.

[View a larger version of this diagram](https://github.com/cloudfoundry/docs-cloudfoundry-concepts/blob/master/images/comparison.png?raw=true).
## <a id='about'></a> About <%= vars.app_runtime_abbr %>
This section describes why <%= vars.app_runtime_abbr %> is an industry-standard cloud platform.
Not all cloud platforms are created equal. Some have limited language and framework support, lack key app services, or restrict deployment to a single cloud.
As an industry-standard cloud platform, <%= vars.app_runtime_abbr %> offers the following:
* **Open source code**: The platform's openness and extensibility prevent its users from being locked into a single framework, set of app services, or cloud. For more information, see the [Cloud Foundry](https://github.com/cloudfoundry) project on GitHub.
* **Deployment automation**: Developers can deploy their apps to <%= vars.app_runtime_abbr %> using their existing tools and with zero modification to their code.
* **Flexible infrastructure**: You can deploy <%= vars.app_runtime_abbr %> to run your apps on your own computing infrastructure, or deploy on an IaaS like vSphere, AWS, Azure, GCP, or OpenStack.
* **Commercial options**: You can also use a PaaS deployed by a commercial <%= vars.app_runtime_abbr %> cloud provider. For more information, see [Cloud Foundry Certified Platforms](https://www.cloudfoundry.org/certified-platforms/).
* **Community support**: A broad community contributes to and supports <%= vars.app_runtime_abbr %>. See [Welcome to the Cloud Foundry Community](https://www.cloudfoundry.org/community/).
<%= vars.app_runtime_abbr %> is ideal for anyone interested in removing the cost and complexity of configuring infrastructure for their apps.
## <a id='how-it-works'></a> How <%= vars.app_runtime_abbr %> Works
To flexibly serve and scale apps online, <%= vars.app_runtime_abbr %> has subsystems that perform specialized functions. The following sections describe how some of these main subsystems work.
### <a id='balances'></a> Load balancing
This section describes how <%= vars.app_runtime_abbr %> handles load balancing.
Clouds balance their processing loads over multiple machines, optimizing for efficiency and resilience against point failure. A <%= vars.app_runtime_abbr %> installation accomplishes this using the following components:
- **BOSH** creates and deploys VMs on top of a physical computing infrastructure, and deploys and runs <%= vars.app_runtime_abbr %> on top of this cloud. To configure the deployment, BOSH follows a manifest document. For more information, see the [BOSH documentation](http://bosh.io).
- **Cloud Controller** runs the apps and other processes on the cloud's VMs, balancing demand and managing app lifecycles. For more information, see [Cloud Controller](./architecture/cloud-controller.html).
- The **Gorouter** routes incoming traffic from the world to the VMs that are running the apps that the traffic demands, usually working with a customer-provided load balancer. For more information, see [<%= vars.app_runtime_abbr %> Routing Architecture](./cf-routing-architecture.html).
### <a id='apps-anywhere'></a> Running apps
This section describes the VMs that run your apps in <%= vars.app_runtime_abbr %> and how the platform packages your apps to run on these VMs.
#### <a id='cf-vms'></a> VMs in <%= vars.app_runtime_abbr %>
<%= vars.app_runtime_abbr %> designates the following types of VMs:
- **Component VMs** make up the platform's infrastructure.
- **Host VMs** host your apps for the outside world.
Within <%= vars.app_runtime_abbr %>, the Diego system distributes the hosted app load over all of the host VMs, and keeps it running and balanced through demand surges, outages, or other changes. Diego accomplishes this through an auction algorithm.
For more information, see [Diego Components and Architecture](./diego/diego-architecture.html).
#### <a id='cf-apps'></a> Distributing apps
To meet demand, multiple host VMs run duplicate instances of the same app. This means that apps must be portable. <%= vars.app_runtime_abbr %> distributes app source code to VMs with everything the VMs need to compile and run the apps locally.
<%= vars.app_runtime_abbr %> includes the following with your app's source code:
- **Stack**: the operating system the app runs on.
- **Buildpack**: contains all languages, libraries, and services that the app uses.
Before sending an app to a VM, the Cloud Controller stages it for delivery by combining the stack, buildpack, and source code into a droplet that the VM can unpack, compile, and run. For simple, standalone apps with no dynamic pointers, the droplet can contain a pre-compiled executable instead of source code, language, and libraries.
For more information, see:
- [Changing Stacks](../devguide/deploy-apps/stacks.html)
- [Buildpacks](../buildpacks/index.html)
- [How Apps Are Staged](./how-applications-are-staged.html)
### <a id='organize'></a> Organizing users and workspaces
This section describes how <%= vars.app_runtime_abbr %> organizes users and workspaces.
<%= vars.app_runtime_abbr %> manages user accounts through two User Account and Authentication (UAA) servers, which support access control as OAuth2 services and can store user information internally, or connect to external user stores through LDAP or SAML.
For more information, see [User Account and Authentication (UAA) Server](./architecture/uaa.html).
The following table describes what the two UAA servers do:
<table><thead>
<tr>
<th width="25%">Server</th>
<th>Purpose</th>
</tr></thead>
<tbody><tr>
<td>First UAA server</td>
<td><ul><li>Grants access to BOSH</li><li>Holds accounts for <%= vars.ops_manager %> operators who deploy runtimes, services, and other software onto the BOSH layer directly</li></ul></td>
</tr>
<tr>
<td>Second UAA server</td>
<td><ul><li>Controls access to the Cloud Controller</li><li>Defines user roles, such as admin, developer, or auditor, and grants them different sets of privileges to run <%= vars.app_runtime_abbr %> commands</li><li>Scopes the roles to separate, compartmentalized orgs and spaces within an installation to manage and track use</li></ul></td>
</tr></tbody>
</table>
For more information, see [Orgs, Spaces, Roles, and Permissions](./roles.html).
### <a id='resources'></a> Storing resources
The following table describes where <%= vars.app_runtime_abbr %> stores resources:
<table><thead>
<tr>
<th>Resource</th>
<th>Storage Location</th>
</tr></thead>
<tbody><tr>
<td><ul><li>Source code</li><li>Buildpacks</li><li>Documentation</li><li>Custom configurations</li><li>Other platform resources</li></ul></td>
<td>GitHub</td>
</tr>
<tr>
<td><ul><li>Large binary files</li><li>Droplets</li></ul></td>
<td>Internal or external blobstore</td>
</tr>
<tr>
<td><ul><li>Internal component states</li><li>Other temporary information</li></ul></td>
<td>MySQL</td>
</tr></tbody>
</table>
### <a id='communicate'></a> Communicating with components
This section describes how <%= vars.app_runtime_abbr %> components communicate with one another.
<%= vars.app_runtime_abbr %> components communicate in the following ways:
* By sending messages internally using HTTP and HTTPS protocols
* By sending NATS messages to each other directly
BOSH Director co-locates a BOSH DNS server on every deployed VM. All VMs keep up-to-date DNS records for all the other VMs in the same foundation. This enables service discovery between VMs.
BOSH DNS allows deployments to continue communicating with VMs even when the VMs' IP addresses change. It also provides client-side load balancing by randomly selecting a healthy VM when multiple VMs are available.
For more information about BOSH DNS, see [Native DNS Support](https://bosh.io/docs/dns/) in the BOSH documentation.
### <a id='monitor'></a> Monitoring and Analyzing
This section describes logging in <%= vars.app_runtime_abbr %>.
<%= vars.app_runtime_abbr %> generates system logs from <%= vars.app_runtime_abbr %> components and app logs from hosted apps. As <%= vars.app_runtime_abbr %> runs, its component and host VMs generate logs and metrics. <%= vars.app_runtime_abbr %> apps also typically generate logs.
The following table describes where <%= vars.app_runtime_abbr %> sends logs:
<table><thead>
<tr>
<th>Log Type</th>
<th>Destination</th>
</tr></thead>
<tbody><tr>
<td><%= vars.app_runtime_abbr %> component logs</td>
<td>Rsyslog agents</td>
</tr>
<tr>
<td><%= vars.app_runtime_abbr %> component metrics</td>
<td>Loggregator</td>
</tr>
<tr>
<td>App logs</td>
<td>Loggregator</td>
</tr></tbody>
</table>
Component logs stream from rsyslog agents, and the cloud operator can configure them to stream out to a syslog drain.
The Loggregator system aggregates the component metrics and app logs into a structured, usable form, the Firehose. You can use all of the output of the Firehose, or direct the output to specific uses, such as monitoring system internals, triggering alerts, or analyzing user behavior, by applying nozzles.
<% if vars.platform_code == "CF" %>
For more information, see <a href="https://docs.cloudfoundry.org/loggregator/architecture.html">Loggregator Architecture</a>.
<% else %>
For more information, see <a href="../loggregator/architecture.html">Loggregator Architecture</a>.
<% end %>
### <a id='services'></a> Using services
This section describes how you can use services with your apps on <%= vars.app_runtime_abbr %>.
Typical apps depend on free or metered services such as databases or third-party APIs. To incorporate these into an app:
1. **Write a Service Broker**: This component manages the life cycle of the service. The Service Broker uses the Service Broker API to advertise a catalog of service offerings to <%= vars.app_runtime_abbr %> apps.
1. **Provision the Service Instance**: Create an instance of the service offering by sending a provision request to the Service Broker API.
1. **Enable apps to access the Service Instance**: Configure the <%= vars.app_runtime_abbr %> app to make calls to the Service Instance using the Service Broker API.
For more information, see [Services](../services/index.html).
<%= vars.concepts_sf_vs_full_header %>
<% if vars.platform_code == 'PCF' %>
<%= partial "/pcf/core/small_footprint_overview" %>
<% else %>
<% end %>
<%= vars.small_footprint_comparison %>
[//]: # (Comment: Below calls vars concept_product_* in book repository template_vars.yml.)
[//]: # ( The vars *_text and *_image hold locations of partial and image files. )
[//]: # ( For private/commercial books, the partial and image files come from a )
[//]: # ( private repository rather than cloudfoundry.org/docs-cloudfoundry-concepts. )
<%= vars.concepts_product_model_header %>
<%# partials for vars.concepts_product_model_text %>
<% if vars.platform_code == 'CF' %>
<%= partial 'overview_model' %>
<% else %>
<%= partial "/pcf/core/pcf_overview_model" %>
<% end %>
<%= vars.concepts_product_model_image %>