Book Image

OpenShift Cookbook

By : Shekhar Gulati
Book Image

OpenShift Cookbook

By: Shekhar Gulati

Overview of this book

Table of Contents (19 chapters)
OpenShift Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Running OpenShift on a Virtual Machine
Index

Adding and managing add-on cartridges


In the Creating an OpenShift application using the rhc command-line client recipe, you learned how to create a new OpenShift application using a web cartridge. Apart from web cartridges, OpenShift also supports a number of add-on cartridges. These cartridges provide functionalities, such as databases, monitoring, cron jobs, database web clients, and others.

In this recipe, you will learn how to install the MySQL 5.5 cartridge to the PHP 5.4 application that you created in the Creating an OpenShift application using the rhc command-line client recipe.

Getting ready

To complete this recipe, you will need rhc installed on your machine. Also, we will make use of the OpenShift application created in the Creating an OpenShift application using the rhc command-line client recipe.

How to do it…

To add the MySQL 5.5 cartridge to our application, run the following command:

$ rhc cartridge-add --app myapp --cartridge mysql-5.5

If you want to start a cartridge, run the...