app_info.rb: fix whitespace
oo-app-info: don't assume rhcloud.com app domain

Bug 1123944 - oo-app-info does not find gears / users based on app fqdn
https://bugzilla.redhat.com/show_bug.cgi?id=1123944

The search for an app fqdn was poorly implemented, as it assumed the
domain on the fqdn is rhcloud.com. This change generalizes the search to
use the configured cloud domain in the fqdn.
Merge pull request #5688 from sosiouxme/bz1123944

Merged by openshift-bot
<mongodb cart> adapt to use SCL-provided mongodb

Bug 1073126
https://bugzilla.redhat.com/show_bug.cgi?id=1073126

Adds `lib/mongodb_context`, which wraps MongoDB executables with
appropriate SCL context

Adds `update_configuration` function: sets up `PATH`, `MANPATH`, and
`LD_LIBRARY_PATH` for shell env

Update `mongo` shell function in `rhcsh`: don't clear `LD_LIBRARY_PATH`
before calling `mongo`, trust the `PATH` variable to find the right
`mongo`, and resolve mongo path into var `mongo_bin`
mongodb cart: address bugs with scaled carts

Bug 1073126
https://bugzilla.redhat.com/show_bug.cgi?id=1073126#c8

Add `publish-ld-library-path-info` hook, lock `mongodb/lib` directory

Also addresses issue with `rhcsh` where correct `mongo` bin isn't
necessarily on the `PATH`
mongodb cart: Support non-SCL systems

Bug 1104072
https://bugzilla.redhat.com/show_bug.cgi?id=1104072

This commit updates the cart spec file to conditionally call the
`mkjournal` script with or without SCL mongo, updates `mongodb_context`
to support non-scl mongo and tweaks `rhcsh` in a similar manner.

Additional fixes include:

* modify the `mongo` function in `rhcsh` to properly quote
  user-specified parameters for passing to `scl enable mongodb24`

* conditionally publish path elements so the correct `mongo*` binaries
  are preferred in scaled and non-scaled environments

* defensively quote user-specified parameters in function `mongo` in
  `rhcsh` so that things like exotic passwords that contain spaces are
  passed to the `mongo` binary without being erroneously split into
  multiple arguments
mongodb cart: clean up `mongodb_context`, `rhcsh`

Integrating Miciah's suggestions to simplify `update_configuration` and
`rhcsh` `mongo` function - smarter path element generation and more
correct handling for empty `ld_path` variables

Squashed commit:

add Vojtech's much smarter path element extraction