Deploy a Rails app to Openshift: rhc - Username or password is not correct - ruby-on-rails

Our company wants to build a Rails-based backend website and we chose the OpenShift platform to host and deploy. To connect the two, all the guides lead to the installation of the ruby rhc gem and then setup it.
I'm fresh to OpenShift and I'm trying to setup the rhc toolkit on a remote Ubuntu server. Now I ran gem install rhc and everything went fine. Since I have to configure rhc through rhc setup, I ran this command afterwards and just after asking which server I want to use (I left it blank to use openshift.redhat.com) it comes to the login part.
At this moment, OpenShift Online allows you to login only with your GitHub account, so I gave in the GitHub credentials and... voilĂ ! Username or password is not correct. Tried this both on PuTTy and ConEmu.
I swear I checked the login data more than 1000 times, and I'm totally lost.
Thank you a lot in advance

If you want to use OpenShift Online NextGen Developer Preview, you do not use the rhc client. You need to use the oc client. So anything you read where it says rhc is the wrong documentation.
Once you are logged in through the new web console, select on the '?' in circle top right and select command line tools. It will give you links to the 'oc' tools to download, plus the command you need to run to login from the command line using a session access token.
The link to that page should be:
https://console.preview.openshift.com/console/command-line
Also suggest you get down and use the free eBook for the new platform at:
https://www.openshift.com/promotions/for-developers.html
It uses a VM, but ignore the client login step from that and use that from page above instead and then follow examples in the book against the Online NextGen Developer Preview instead.

Related

WARNING! ejabberd can not start Admin user is not created Please check your configuration

My title is my "error" that I am facing in the Terminal when setup the ejabberd.
What I did.
Download package from this website and choose Mac OS X Intel Installer.
I'm following this tutorial.
Where I'm reach at /Applications/ejabberd-16.06/bin by Terminal.
And run ./postinstall.sh cesare jerry.local password
And got below error message in terminal.
WARNING ! ejabberd can not start Admin user is not created Please check your configuration
But I know there is instruction that 'postinstall.sh' script, which has to be run right after the installation to create the admin user.
So For create admin user I go on official site of ejabberd.
But there I can't understand 5th step and my registering process alway in progress .
In short how can I create admin user or how can I remove WARNING from the terminal?
COMMENT : After couples of the days, I found that instead of insall ejabberd with Operating System Specific Packagesr you should try to install ejabberd with Binary Installer.
You do not need to run postinstall.sh script as it is already run by the installer and create the admin user for you. If you have had no error message from the installer, you should already be set. You can just call ejabberd start script.
Please make sure that you also approve listening on ports if OSX firewall ask you to authorise it. Ensure also that the user installing ejabberd has admin rights.

rhc setup failure - msg "OpenShift server is not responding correctly"

Yesterday Aug 19 2014, I created a new scalable rails 4 application. Attempting to connect with rhc setup wizard tells me there is an error. Here is the output with sensitive data replaced respectively:
Using [myaccount] to login to myapp-mydomain.rhcloud.com
The OpenShift server is not responding correctly. Check that 'https://myapp-mydomain.rhcloud.com/broker/rest/api' is the correct URL for your server. The server may be offline or misconfigured.
Examining the app through openshift site, everything appears to be setup correctly. I compared it to another app which I do have running and other than the scalable feature, all settings seem to be OK.
I did see a message from OpenShift a few days ago that they were having some trouble, I am wondering if this is still the case and my app did not create correctly?
When you run rhc setup you shouldn't change the value of the server.
Use the default server hostname openshift.redhat.com
Use this command to use different account rhc setup --clean.

Rails + Capistrano + Git: Steps to successfully deploy an app?

We use git for version control. Right now only my account seems to be able to deploy successfully to a remote server for several apps, but I don't know why. I would like to set it up so that deploying works for other people at my company, but I don't really have the full picture laid out in my head so I don't know what needs to be done.
To me it seems like whoever wants to deploy needs a: user account on the server, an account on github, and permission to pull...? However, other users seem to have the notorious Permission denied (publickey). fatal: The remote end hung up unexpectedly and other errors.
Can anyone provide a short list of what I need to do on the server (make an account, add ssh keys or something?) and git (ssh keys again? not sure) to get the deploy to work?
Capistrano assumes you can ssh into the server you are deploying to. You are probably using a communal apps, deployer, or some other app-specific user to deploy your app. This will be the user that is set in your deploy.rb file.
You will need to copy everyone's public key into the authorized_keys of whatever your deploying user is. That is just how Capistrano works.

Brand new Heroku CLI installation authentication failed

This question might be considered duplicate of this: Unable to use heroku gem cli after password changes, but it is not.
In my case I have the latest Mac OS X 10.8.3 and I've installed brand new Heroku tool belt. First thing I've tried is to authenticate by issuing this:
heroku login
I was asked for my Heroku credentials, which I've entered (many-many times), but I got "Authentication Failed" message.
I've tried signing in with my credentials to Heroku website multiple times from different browsers - it all works, but I can't authenticate with Heroku CLI.
I don't have ~/.netrc file, I don't have any fancy firewall software on my Mac. What am I possibly doing wrong?
Thanks,
Alex.
Update 03/18/2013 9 PM Mountain:
This is the Heroku issue and they are looking into it:
Sounds like it might be an SSH key issue.
Here is a good guide to resolving it.
https://devcenter.heroku.com/articles/keys
Heroku engineers have fixed it and I was able to authenticate. Thank you, Heroku!

OCIError (ruby on rails)

I am using rails freeze 1.2.3 to run a rails app. Because the app is on a remote machine, I used ssh tunnel (ssh -l -L) to show the app on my screen. When I ran it, it correctly prompted the login page, after I put in the info, I got this error:
OCIError in ServiceController
Error while trying to retrieve text for error ORA-12154
I have tried the same app on a different machine w/o using freeze (because that machine has rails version 1.2.3 while current one has 2.0.2). Is that where the error comes from?
Thanks.
That's an Oracle error. It sounds like your database setup is incorrect. Put the error number ORA-12154 in Google and you'll find some useful stuff.
ORA-12154 is a classic. As Sarah points out its nothing to do with your Rails or Ruby per se. ORA-12154 is generated when the Oracle Client can't connect to the oracle server. So most likely your setup is wrong in:
Your database.yml, if you can connect using tnsping or sqlplus (Oracle client utils) you probably just need to look at this.
Your Oracle networking setup, particularly your tnsnames.ora file (found in $ORACLE_HOME/network/admin if I remember correctly). This may need some extra help from a friendly DBA as the tnsnames.ora syntax has quirks. Check this link link text for more info.
Hope that helps.

Resources