Try PCF on the Public Cloud

15-minute tutorial for learning Pivotal Cloud Foundry app deployment concepts

Connect a Database

PCF enables administrators to provide a variety of services on the platform that can easily be consumed by applications.

List the available ElephantSQL plans:

cf marketplace -s elephantsql

Create a service instance with the free plan:

cf create-service elephantsql turtle cf-spring-db

Bind the newly created service to the app:

cf bind-service cf-spring cf-spring-db

Once a service is bound to an app, environment variables are stored that allow the app to connect to the service after a push, restage, or restart command.

Restage the app:

cf restage cf-spring

Verify the new service is bound to the app:

cf services