openshift/wordpress-example — pull request #17 by msmith (2012-08-02 20:28:04+00:00)
Title: Use OPENSHIFT_DB_PORT environment variable

This patch enables the wordpress-example to be used on OpenShift when auto-scaling is enabled.

It uses the OPENSHIFT_DB_PORT environment variable to connect to mysql. Previously, the port number was not specified, so it was using the default mysql port (3306).

Apparently, when you add the mysql cartridge to a non-scaled OpenShift app, the mysql port number is 3306, so this was working. However, when you add the mysql cartridge to a scaled OpenShift app (created with `rhc app create -s`), then it will use a non-standard port for mysql.