Bug 1389482

Summary: oauth stops working in jenkins image
Product: OKD Reporter: Ben Parees <bparees>
Component: ImageAssignee: Gabe Montero <gmontero>
Status: CLOSED CURRENTRELEASE QA Contact: Wang Haoran <haowang>
Severity: high Docs Contact:
Priority: high    
Version: 3.xCC: aos-bugs, dyan, mmccomas
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-12-09 21:53:31 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 Ben Parees 2016-10-27 17:13:01 UTC
Description of problem:
When using the oauth flow in the jenkins image, after deleting a pipeline buildconfiguration from openshift, the user gets a read access permission denied error in the jenkins console and can no longer access the console.  Upon logging out, the user is presented with the non-oauth login flow.

Comment 1 Gabe Montero 2016-10-27 18:00:57 UTC
deleting a job in general based on jenkins log analysis seems to induced a bootup cycle of sorts in Jenkins (see InitReactorRunner.java in the jenkins core).  aside from deleting the bc, i was able to log into jenkins and manually delete the sample-pipeline job and achieve the same effect.

This bootup cycle has the effect of resetting the system to the standard jenkins login (overriding our dynamic override of the login provider to oauth).

I'll need to either using the existing listeners / filters already in play, or also use the plug points that sync plugin uses, to learn of this job deleting and re-institute.

Comment 2 Gabe Montero 2016-10-28 02:59:11 UTC
the jenkins-*-centos7 images have been updated with v0.3 of the openshift-login plugin, which has the fix for this bug, and pushed to docker.io

Comment 3 Dongbo Yan 2016-10-28 06:04:03 UTC
Verified
docker.io/openshift/jenkins-1-centos7   5b7b34dd4518
openshift-login	0.3

openshift v3.4.0.16+cc70b72
kubernetes v1.4.0+776c994
etcd 3.1.0-rc.0