Spring Cloud Services v1.3

Creating an Instance

Page last updated:

You can create a Config Server service instance using either the Cloud Foundry Command Line Interface tool (cf CLI) or Pivotal Cloud Foundry® Apps Manager (you cannot configure a service instance using Apps Manager).

Using the cf CLI

Begin by targeting the correct org and space.

$ cf target -o myorg -s development

API endpoint: (API version: 2.43.0)
User:           user
Org:            myorg
Space:          development

You can view plan details for the Config Server product using cf marketplace -s.

$ cf marketplace
Getting services from marketplace in org myorg / space development as user...

service                       plans          description
p-circuit-breaker-dashboard   standard       Circuit Breaker Dashboard for Spring Cloud Applications
p-config-server               standard       Config Server for Spring Cloud Applications
p-mysql                       100mb-dev      MySQL service for application development and testing
p-rabbitmq                    standard       RabbitMQ is a robust and scalable high-performance multi-protocol messaging broker.
p-service-registry            standard       Service Registry for Spring Cloud Applications

TIP:  Use 'cf marketplace -s SERVICE' to view descriptions of individual plans of a given service.

$ cf marketplace -s p-config-server
Getting service plan information for service p-config-server as user...

service plan   description     free or paid
standard       Standard Plan   free

Create the service instance using cf create-service, using the -c flag to provide a JSON object that specifies the configuration parameters. For information about the parameters used to configure a Git configuration source, see the Configuring with Git topic.

General parameters accepted for the Config Server are listed below.

Parameter Function Example
count The number of nodes to provision: 1 by default, more for running in high-availability mode '{"count": 3}'
upgrade Whether to upgrade the instance '{"upgrade": true}'

To create an instance, specifying settings for Git configuration sources and that three nodes should be provisioned:

$ cf create-service -c '{"git": { "uri": "", "repos": { "cook": { "pattern": "cook*", "uri": "" } } }, "count": 3 }' p-config-server standard config-server
Creating service instance config-server in org myorg / space development as user...

Create in progress. Use 'cf services' or 'cf service config-server' to check operation status.

As the command output suggests, you can use the cf services or cf service commands to check the status of the service instance. When the service instance is ready, the cf service command will give a status of create succeeded:

$ cf service config-server

Service instance: config-server
Service: p-config-server
Bound apps:
Plan: standard
Description: Config Server for Spring Cloud Applications
Documentation url:

Last Operation
Status: create succeeded
Started: 2016-06-24T21:57:21Z
Updated: 2016-06-24T21:59:24Z

Important: The cf service and cf services commands may report a create succeeded status even if the Config Server cannot initialize using the provided settings. For example, given an invalid URI for a configuration source, the service instance may still be created and have a create succeeded status.

If the service instance does not appear to be functioning correctly, you can visit its dashboard to double-check that the provided settings are valid and accurate. See the Using the Dashboard topic.

Note: You may notice a discrepancy between the status given for a service instance by the cf CLI (e.g., by the cf service command) versus that shown on the Service Instances dashboard. The dashboard is updated frequently (close to real-time); the status retrieved by the cf CLI is not updated as frequently and may take time to match the dashboard.

Using Apps Manager

Note: If you create a Config Server service instance using Apps Manager, you will need to use the cf CLI to update the service instance and provide settings (including one or more configuration sources) before the instance will be usable. For information on updating a Config Server service instance, see the Updating an Instance topic.

Log into Apps Manager as a Space Developer. In the Marketplace, select Config Server.


Select the desired plan for the new service instance.

Select plan

Provide a name for the service instance (for example, “config-server”). Click the Add button.

Instance name

In the Services list, click the Manage link under the listing for the new service instance.

Service successfully added

It may take a few minutes to provision the service instance; while it is being provisioned, you will see a “The service instance is initializing” message. When the instance is ready, its dashboard will load automatically.

Dashboard new

The dashboard displays the current settings for the Config Server service instance. Before you can use this service instance, you must update it using the cf CLI to supply it with a configuration source. For information about updating a service instance to configure instance settings, see the Updating an Instance topic.

Create a pull request or raise an issue on the source for this page in GitHub