Skip to content
This repository has been archived by the owner on Aug 29, 2018. It is now read-only.

Commit

Permalink
Follow up fix for Bug 970150
Browse files Browse the repository at this point in the history
It turns out that 6400c02 wasn't really working.
The inner `if` clause, `$?` is `0` no matter what the result from
the app name check, so that any app name would fail for Rails.

This fixes that.
  • Loading branch information
BanzaiMan committed Aug 13, 2013
1 parent f219aae commit b46b39c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions cartridges/openshift-origin-cartridge-ruby/bin/control
Expand Up @@ -191,8 +191,7 @@ function rails_app_name_check() {
if [ -f Gemfile.lock ]; then
grep 'rails' Gemfile.lock 2>&1 >/dev/null
if [ $? -eq 0 ]; then
echo "$OPENSHIFT_APP_NAME" | grep '^[0-9]' >/dev/null
if [ $? -eq 0 ]; then
if $(echo "$OPENSHIFT_APP_NAME" | grep '^[0-9]' >/dev/null); then
client_error "Invalid Rails application name. Please delete this application and re-create it with a name which does not start with numbers"
exit 1
fi
Expand Down

0 comments on commit b46b39c

Please sign in to comment.