Bug 1010940

Summary: Jenkins-client will be added into the app when adding jenkins-client without jenkins server in the domain
Product: OpenShift Online Reporter: Lei Zhang <lzhang>
Component: PodAssignee: Abhishek Gupta <abhgupta>
Status: CLOSED CURRENTRELEASE QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 2.xCC: abhgupta, xtian
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-10-17 13:30:48 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Lei Zhang 2013-09-23 10:36:35 UTC
Description of problem:
Given one normal app created(e.g., myphp), add jenkins-client to the app without jenkins server in the domain, and then show the app information.

[rayzhang@ray Work]$ rhc app create myphp php-5.3 
Application Options
-------------------
  Namespace:  ray1
  Cartridges: php-5.3
  Gear Size:  default
  Scaling:    no
.......................
.......................

Your application 'myphp' is now available.

[rayzhang@ray Work]$ rhc cartridge add -a  myphp -c jenkins-client-1 
Adding jenkins-client-1 to application 'myphp' ... 
A Jenkins server does not exist in this domain!
You must create a Jenkins server before installing this cartridge.

[rayzhang@ray Work]$ rhc app show myphp
myphp @ http://myphp-ray1.dev.rhcloud.com/ (uuid: 52400b6fa35a81ee5b000095)
---------------------------------------------------------------------------
  Domain:  ray1
  Created: 5:35 PM
  Gears:   1 (defaults to small)
  Git URL: ssh://52400b6fa35a81ee5b000095.rhcloud.com/~/git/myphp.git/
  SSH:     52400b6fa35a81ee5b000095.rhcloud.com
  php-5.3 (PHP 5.3)
  -----------------
    Gears: Located with jenkins-client-1
  jenkins-client-1 (Jenkins Client)
  ---------------------------------
    Gears: Located with php-5.3


Version-Release number of selected component (if applicable):
devenv-3810

How reproducible:
always

Steps to Reproduce:
1. Create one app
#rhc app create myphp php-5.3 
2. Add jenkins-client to the app without jenkins server in the domain
#rhc cartridge add -a  myphp -c jenkins-client-1
3. Show the app information 
#rhc app show myphp

Actual results:
Jenkins-client can be added into the app without jenkins server in the domain

Expected results:
Jenkins-client should not be added into the app without jenkins server in the domain 

Additional info:

Comment 1 Jhon Honce 2013-09-23 16:08:42 UTC
Using devenv_3812

# rhc app create myphp php-5.3

# rhc cartridge add -a  myphp -c jenkins-client-1
Adding jenkins-client-1 to application 'myphp' ... 
A Jenkins server does not exist in this domain!
You must create a Jenkins server before installing this cartridge.

Please re-open with additional instructions if you can reproduce.

Comment 2 Lei Zhang 2013-09-24 01:24:40 UTC
devenv_3814, When adding jenkins-client, It will show warning message, but jenkins-client has been added into the app.

Need 3 Steps:
Step 1
#rhc app create myphp php-5.3

Step 2
#rhc cartridge add -a  myphp -c jenkins-client-1
Adding jenkins-client-1 to application 'myphp' ... 
A Jenkins server does not exist in this domain!
You must create a Jenkins server before installing this cartridge.

Step 3
#rhc app show myphp
myphp @ http://myphp-chunchen.dev.rhcloud.com/ (uuid: 5240e86be5c99110fc000001)
-------------------------------------------------------------------------------
  Domain:  chunchen
  Created: 9:18 AM
  Gears:   1 (defaults to small)
  Git URL: ssh://5240e86be5c99110fc000001.rhcloud.com/~/git/myphp.git/
  SSH:     5240e86be5c99110fc000001.rhcloud.com

  php-5.3 (PHP 5.3)
  -----------------
    Gears: Located with jenkins-client-1

  jenkins-client-1 (Jenkins Client)
  ---------------------------------
    Gears: Located with php-5.3

you see, jenkins-client-1 has been added into the app.

Comment 3 Abhishek Gupta 2013-09-24 21:37:25 UTC
Cannot reproduce it anymore. I believe it was fixed with --> https://github.com/openshift/origin-server/pull/3683

Comment 4 Lei Zhang 2013-09-25 06:10:17 UTC
Verified on devenv_3824

[rayzhang@ray Work]$ rhc apps
myphp @ http://myphp-chunchen.dev.rhcloud.com/ (uuid: 5242746ec48d1eec2a000032)
-------------------------------------------------------------------------------
  Domain:  chunchen
  Created: 1:28 PM
  Gears:   1 (defaults to small)
  Git URL: ssh://5242746ec48d1eec2a000032.rhcloud.com/~/git/myphp.git/
  SSH:     5242746ec48d1eec2a000032.rhcloud.com

  php-5.3 (PHP 5.3)
  -----------------
    Gears: 1 small

You have 1 applications
[rayzhang@ray Work]$ rhc cartridge add -a myphp -c jenkins-client-1
Adding jenkins-client-1 to application 'myphp' ... 
A Jenkins server does not exist in this domain!
You must create a Jenkins server before installing this cartridge.

[rayzhang@ray Work]$ rhc app show myphp
myphp @ http://myphp-chunchen.dev.rhcloud.com/ (uuid: 5242746ec48d1eec2a000032)
-------------------------------------------------------------------------------
  Domain:  chunchen
  Created: 1:28 PM
  Gears:   1 (defaults to small)
  Git URL: ssh://5242746ec48d1eec2a000032.rhcloud.com/~/git/myphp.git/
  SSH:     5242746ec48d1eec2a000032.rhcloud.com

  php-5.3 (PHP 5.3)
  -----------------
    Gears: 1 small