The Ecosystem of PCF Tiles: Easier Deployment and Upgrades
Taking the modular approach
Pivotal Cloud Foundry (PCF) tiles “provide a modular and standardized interface that PCF operators use to configure, publish, manage, and upgrade software services, whether the services are for their own use, or for use by the PCF app developers,” according to the official documentation from Pivotal.
Simply put, tiles are integrations of third-party services for the Pivotal CF platform. Users work through a service broker and APIs with particular services—whether we’re talking about environments such as AWS or popular data stores such as Cassandra.
A couple of days ago, Andrei Krasnitski (a Cloud Foundry Engineer at Altoros) took webinar participants beyond the official definition.
PCF tile structure
As Pivotal CF supports integration with any software service, they are distributed as the PCF tiles on the Pivotal Network. To add a tile to a PCF installation, one needs to download the tile file from the Pivotal Network and install it using the Ops Manager Installation Dashboard. Through a unified interface that tiles provide, PCF operators can configure, publish, manage, and upgrade the services.
On the Pivotal Network, tiles are distributed as zipped-code directories with the
.pivotal filename extension that contains all of the software elements to perform the tile’s functions.
So, a typical structure of a tile directory comprises the following elements:
- BOSH release is a collection of configuration properties, templates, scripts, source code, and binary artifacts required to build and deploy software in a reproducible way.
- Tile manifest template contains the deployment manifest, which is used for configuring and publishing a data service. This manifest describes configuration interface of the tile installation in the Ops Manager Installation Dashboard.
In addition, tile directories include the following three top-level subdirectories:
metadata, which is high-level information for configuring and publishing services.
migrations, which are basically the rules to govern tile upgrades.
releases, or to be exact, the BOSH releases that deploy the services of interest.
How PCF tiles work
A service broker is the core element of a tile. Service brokers enable developers to create service instances and bind them to apps by providing an interface between the Cloud Controller and the software service it represents.
“The service can run internally or externally to a PCF deployment, but the service broker always runs inside the Cloud Foundry installation.” —Andrei Krasnitski
So, how does a PCF tile function and what is it capable of? A tile:
- Deploys a service broker, as already mentioned, to provide an interface between the Cloud Controller and a service.
- Publishes a catalog of available service plans to the Services Marketplace. Service brokers include a metadata catalog of their service plans. This information is published to the Pivotal Marketplace for the use of app developers and PCF operators.
- Defines an interface for configuring service properties in Ops Manager. Operators can configure services through a form-based interface in the Ops Manager Installation Dashboard. These updated properties become a part of the BOSH manifest, which is used by PCF for deploying service instances.
- Generates a BOSH manifest for deploying instances of the service.
- Runs post-deploy errands and pre-delete errands. Post-deploy errands run after product installation, but before Ops Manager makes it available for use. Pre-delete errands run after an operator chooses to delete a product, but before Ops Manager finishes removing it.
- Defines service dependencies for the tile to prevent Ops Manager from installing the service when dependencies are missing. This is done by including product dependencies at the top of the tile manifest file.
- Supports one-click installation and upgrades from previous versions.
“Each service’s tile acts as a wrapper for a service broker. During the tile installation, it creates its own service broker and registers it in the Cloud Controller.” —Andrei Krasnitski
Designed for five groups of needs
Pivotal Network offers a great number of tiles to integrate the service of interest. According to Andrei, PCF tiles can be broadly divided into five groups that address a particular set of needs:
- Tiles to install and manage the Pivotal CF platform (e.g., Pivotal Cloud Foundry Elastic Runtime, Pivotal Cloud Foundry Ops Manager, or Buildpacks for PCF).
- Tiles to accelerate the process of building and delivering cloud apps (e.g., Pivotal tc Server and Spring Cloud Services for PCF).
- Service SDKs to build solutions of one’s own for the Pivotal Cloud Foundry Marketplace (e.g., On-Demand Services SDK and Service Metrics SDK).
- “Data” tiles that extend your deployment with various data management systems like Hadoop and Gemfire.
- “Services” tiles—the most numerous on the network—to integrates various data services with a PCF installation (Redis for PCF, RabbitMQ for PCF, MySQL for PCF, etc.).
Andrei exemplified a few PCF tiles, noting that the Elastic Runtime tile, for instance, is usually the starting point for anyone new to the network offerings.
There are also the tiles that serve the needs of different cloud infrastructures. For instance, developers can choose from these tiles to expand cloud capabilities:
- PCF Service Broker for AWS that provides the ability to create and manage AWS resources using the Cloud Foundry CLI.
- Azure Service Broker that extends Cloud Foundry with the Azure-managed services that can be consumed by applications.
- GCP Service Broker that exposes the selected Google Cloud Platform services in the marketplace. Developers can then provision GCP services by creating and managing service instances with the Cloud Foundry CLI.
For users running self-managed virtualization platforms, such as vSphere or OpenStack, installation of popular data services is possible using the MySQL, Redis, and RabbitMQ tiles.
Tiles for CI/CD, logging, monitoring, and more
The Pivotal Network features a large amount of tiles developed by the company’s partners. This group includes integrations for NoSQL and in-memory databases, message brokers, CI/CD solutions like GitLab, logging solutions like Splunk Firehose Nozzle, etc.
We at Altoros have also added our share to the network. Currently, there are six tiles available in a public beta:
- Based on the open-source Jenkins version, Jenkins for PCF uses Jenkins Docker Plugin for automated followers provisioning.
- Logsearch for PCF is a multi-tenant ELK-based solution that provides log aggregation and parsing algorithms for PCF operators and developers. It comes with pre-configured dashboards and search queries to start log analysis. One can also collect both PCF applications and component logs with the tile.
- Cassandra for PCF installs an open-source version of Apache Cassandra, registers a service broker, and exposes service plans on the marketplace. It also enables automated backups.
- Elasticsearch for PCF deploys an Elasticsearch cluster in a highly available mode. The tile installs a service broker that enables Elasticsearch cluster in a multi-tenant mode.
- AWS S3 for PCF registers a service broker on PCF and exposes its service plans on the marketplace.
- Heartbeat for PCF is a multi-tenant monitoring solution. The service stores, pulls, visualizes, and sends alters on the metrics emitted by VMs, PCF components, services, and apps running on Pivotal Cloud Foundry. The tile also comes with pre-built integration with some other tiles published on the Pivotal Network.
During the webinar, Andrei also conducted a live demonstration of how to install PCF tiles and how to bind the service to an app. Want details? Check out the full webinar recording.
- Altoros Heartbeat Adds Full-Stack Monitoring for Pivotal Cloud Foundry
- Migrating Pivotal Cloud Foundry to a Multi-AZ Deployment
About the expert
with assistance from Andrei Krasnitski, Roger Strukhoff, and Alex Khizhniak.