Bug 807443

Summary: after embedding a backend cartridge, rhc client tools returns the raw values rather than hinting towards our best practice to use Env Vars
Product: OKD Reporter: Nam Duong <nduong>
Component: ContainersAssignee: Jhon Honce <jhonce>
Status: CLOSED CURRENTRELEASE QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 1.xCC: ccoleman, dmcphers, jhou, jofernan, johnp, mmcgrath, mpatel
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-11-06 18:49:25 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Nam Duong 2012-03-27 19:33:57 UTC
Description of problem:
This is user feedback:
[12:30]  <sontek> Yeah, I thought it was weird the cartridge spat out an IP address
[12:30]  <sontek> but figured I would use it since thats what it gave me

In context, we were discussing why the IP for the db might change on randomly on upgrade without notification to the user.  I explained that we do so for efficiency (moving gear to the right nodes, but didn't use that terminology yet).  The user was confused because we returned IP value but didn't hint on using Env variables.

Comment 1 John (J5) Palmieri 2012-03-29 21:07:27 UTC
We get whatever the backend sends back to us.  The client has no context or structured data in which to give a better notice to the user.  This is a backend issue.

Comment 2 John (J5) Palmieri 2012-08-14 17:28:32 UTC
Retaking this.  While working with cartridges this sprint I noticed that this is now implemented by the backend.  I will take a look at this for RHC.  We probably need a story for the site.

Comment 3 Jhon Honce 2012-10-10 23:33:56 UTC
Cartridge changes under review https://github.com/jwhonce/origin-server/commit/ba9114fd1b755147fe2f81772bca272bf641bc45

Comment 4 Jhon Honce 2012-10-11 16:52:49 UTC
Fixed in https://github.com/openshift/origin-server/pull/648

Comment 5 Jianwei Hou 2012-10-12 09:29:32 UTC
Verified on devenv_2138

Now we use Env vars instead of ip:port

Steps:
1. Create an application
2. Embed db cartridge to it

mongodb-2.2:
MongoDB 2.2 database added.  Please make note of these credentials:

       Root User: admin
   Root Password: W44DGr551zhZ
   Database Name: php1s

Connection URL: mongodb://$OPENSHIFT_GEAR_DNS:$OPENSHIFT_MONGODB_DB_PROXY_PORT/
MongoDB gear-local connection URL: mongodb://$OPENSHIFT_MONGODB_DB_HOST:$OPENSHIFT_MONGODB_DB_PORT/

mysql-5.1:
MySQL 5.1 database added.  Please make note of these credentials:

   Root User: admin
   Root Password: HWy-gsPMQsux
   Database Name: php1s

Connection URL: mysql://$OPENSHIFT_GEAR_DNS:$OPENSHIFT_MYSQL_DB_PROXY_PORT/
MySQL gear-local connection URL: mysql://$OPENSHIFT_MYSQL_DB_HOST:$OPENSHIFT_MYSQL_DB_PORT/


postgresql-8.4:
PostgreSQL 8.4 database added.  Please make note of these credentials:

   Root User: admin
   Root Password: IXRQK32P2PJU
   Database Name: php1s

Connection URL: postgresql://$OPENSHIFT_GEAR_DNS:$OPENSHIFT_POSTGRESQL_DB_PROXY_PORT/
PostgreSQL gear-local connection URL: postgresql://$OPENSHIFT_POSTGRESQL_DB_HOST:$OPENSHIFT_POSTGRESQL_DB_PORT/