OpenShift PaaS Weekly Tips and Tricks - August 12, 2012

Platform-as-a-service makes deploying applications to cloud fast and easy.  But, to get the most out of the OpenShift PaaS, it helps to stay abreast of the interesting technical issues plus their workarounds and solutions.  We've made this easy with a weekly tips and tricks blog.

Not receiving email confirmation on signup

We've created an FAQ and added some tips on how to complete the signup process and email confirmations:  https://openshift.redhat.com/community/faq/i-just-signed-up-why-didnt-i-receive-an-email-confirmation

rhc gem installation and run issues

As the rhc client tools is Ruby gem, you may run into various gem-related errors at installation and runtime.  We've worked through some of those within the community and have created a KB article around them:  https://openshift.redhat.com/community/kb/kb-e1062-errors-when-trying-to-install-or-execute-rhc-client-commands

Platform-as-a-service makes deploying applications to cloud fast and easy.  But, to get the most out of the OpenShift PaaS, it helps to stay abreast of the interesting technical issues plus their workarounds and solutions.  We've made this easy with a weekly tips and tricks blog.

Not receiving email confirmation on signup

We've created an FAQ and added some tips on how to complete the signup process and email confirmations:  https://www.openshift.com/faq/i-just-signed-up-why-didnt-i-receive-an-email-confirmation

rhc gem installation and run issues

As the rhc client tools is Ruby gem, you may run into various gem-related errors at installation and runtime.  We've worked through some of those within the community and have created a KB article around them:  https://www.openshift.com/kb/kb-e1062-errors-when-trying-to-install-or-execute-rhc-client-commands

Application level gem installation issues for Ruby applications

While we're on the subject of Ruby gems, here are some tips on how you can install them on OpenShift to resolve app dependencies:  https://www.openshift.com/forums/openshift/problems-installing-the-ruby-gem-whois
If they aren't being installed on git push, you may need to clear the cache with tips from here:  https://www.openshift.com/kb/kb-e1061-rubygems-are-not-installing-on-push-using-bundler

Installing RPMs on OpenShift

With app level dependencies, you may find that an RPM your app needs is not installed on the platform.  As most of us are aware, you can't simply use Yum to install on OpenShift due to restrictions on what you can and can't do on your gear.  There is a workaround that's outlined here:  https://www.openshift.com/forums/openshift/is-it-possible-to-use-rpm-to-install-soft-and-resolve-dependencies

Debugging your application errors with logs

The best way to review your application logs for errors remotely is to run "rhc app tail -a {appName}", but that may not give you everything you're looking for.  For completeness, you'll want to ssh onto the gear on which the component/cartridge is installed using this:  https://www.openshift.com/faq/can-i-access-my-applications-gear
application logs:  more ~/{appName}/logs/*.log
cartridge logs: more ~/{cartridgeID}/log/*.log
Build-time logs are returned to the console on git push, so look for build failures there as well as Jenkins build logs if you're using Jenkins.

JBoss data sources

Another common issue is around configuring JBoss data sources.  We're still working on the following issue, but the forum thread has a great example on how use the data sources that are pre-configured JBoss on OpenShift:  https://www.openshift.com/forums/openshift/error-msc000001-failed-to-start-service-jbossdeploymentunitrootwarparse

JBoss JDBC Realm

Here's a great example on how to configure user/security for your JBoss app:  https://www.openshift.com/forums/openshift/jboss7-jdbc-realm

How to modify MySQL's my.cnf

We've enabled the ability to modify your MySQL instance on OpenShift.  Just ssh onto the mysql gear:
https://www.openshift.com/faq/can-i-access-my-applications-gear
and modify my.cnf:  https://www.openshift.com/forums/openshift/accessing-myconf-for-mysql

Tomcat on DIY - startup and shutdown issues

As more of us are deploying Tomcat applications, there are some increase in issues surrounding port conflict/binding issues so we added some more tips on how to avoid that here: https://www.openshift.com/forums/openshift/solved-tomcat-diy-is-not-able-to-start-anymore#comment-23081

Special thanks to all Community users who helped report these issues on IRC, Forums and the mailing list.  Without you, we won't know what we have to fix nor how we can improve.  So please keep the questions coming!!

Thank you!
--
Nam Duong - Customer Enablement
Product Marketing Manager
OpenShift | PaaS by Red Hat

http://openshift.redhat.com
Twitter: @openshift, @NamDuong_rh