Bug 1512793

Summary: fail to re-install ocp with ansible-service-catalog deployed
Product: OpenShift Container Platform Reporter: liujia <jiajliu>
Component: Service BrokerAssignee: Fabian von Feilitzsch <fabian>
Status: CLOSED ERRATA QA Contact: Zhang Cheng <chezhang>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.7.0CC: aos-bugs, bandrade, jmatthew, jokerman, mmccomas, tlarsson
Target Milestone: ---   
Target Release: 3.7.z   
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: 2017-12-18 13:23:56 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:
Embargoed:

Description liujia 2017-11-14 06:35:48 UTC
Description of problem:
Run config.yml against v3.7 ocp with ansible-service-catalog deployed on it. Re-install failed at task [ansible_service_broker : create ansible-service-broker service].

fatal: [x.x.x.x]: FAILED! => {"changed": false, "failed": true, "msg": {"cmd": "/usr/bin/oc replace -f /tmp/asb-pUz9c3 -n openshift-ansible-service-broker", "results": {}, "returncode": 1, "stderr": "The Service \"asb\" is invalid: spec.clusterIP: Invalid value: \"\": field is immutable\n", "stdout": ""}}

Version-Release number of the following components:
openshift-ansible-3.7.7-1.git.0.3e1b62b.el7.noarch.rpm

How reproducible:
always

Steps to Reproduce:
1. Install ocp v3.7 with asb installed by default.
openshift_service_catalog_image_prefix: x.x.x.x
ansible_service_broker_image_prefix: x.x.x.x
template_service_broker_prefix: x.x.x.x
2. Re-install
3.

Actual results:
Re-install failed.

Expected results:
Re-install succeed.

Additional info:
Please attach logs from ansible-playbook with the -vvv flag

Comment 1 Fabian von Feilitzsch 2017-11-27 20:36:33 UTC
https://github.com/openshift/openshift-ansible/pull/6276
https://github.com/openshift/openshift-ansible/pull/6277

Should fix or work around the idempotence issues.

Comment 2 openshift-github-bot 2017-12-01 16:26:24 UTC
Commits pushed to master at https://github.com/openshift/openshift-ansible

https://github.com/openshift/openshift-ansible/commit/4f72e8a10da24aa231498c897db1153ef51ba2ee
Bug 1512793- Fix idempotence issues in ASB deploy

- Add support for annotations in oc_service
- Use oc_service instead of oc_obj
- Use oc_pvc instead of oc_obj
- Work around lack of idempotency for oc_obj DeploymentConfig

https://github.com/openshift/openshift-ansible/commit/e0e10698184c9a7cf4bf65787771686e46d26603
Merge pull request #6277 from fabianvf/asb-idempotence-cpick

Bug 1512793- Fix idempotence issues in ASB deploy

Comment 4 Zhang Cheng 2017-12-05 06:44:03 UTC
Verified with openshift-ansible-3.7.11-1, re-installed succeed. LGTM

Comment 7 errata-xmlrpc 2017-12-18 13:23:56 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:3464