Configuring MySQL on Cloud Foundry

For persistence support with the monitoring application, you need to configure MySQL with either a marketplace service or a user-provided service.

 

Creating Service from the Marketplace

  1. You can check the services available from the Cloud Foundry Marketplace by running the following command:

    cf marketplace

  2. Run the following command to create a service.

    cf create-service <SERVICE_NAME><SERVICE_PLAN> <SERVICE_INSTANCE_NAME>

Note: Define the <SERVICE_INSTANCE_NAME> as bwcemon_mysql

MySQL is now configured with the marketplace service on the Cloud Foundry environment.

Creating a User Provided Service for MySQL

  1. To create the User Provided Service (CUPS) for the MySQL database, run the following command:

    cf cups <service_instances_name> -p "host,username,password,database"

     

MySQL is now configured with the user-provided service on the Cloud Foundry environment.