Bug 1531949 - openshift-ansible install is not respecting oreg_url and/or service-catalog image prefix var(s)
Summary: openshift-ansible install is not respecting oreg_url and/or service-catalog i...
Keywords:
Status: CLOSED DUPLICATE of bug 1516534
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer
Version: 3.9.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 3.9.0
Assignee: Fabian von Feilitzsch
QA Contact: Johnny Liu
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-01-06 19:25 UTC by Nicholas Schuetz
Modified: 2018-01-22 17:42 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-01-22 17:42:21 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Nicholas Schuetz 2018-01-06 19:25:59 UTC
# rpm -qa |grep playbook
openshift-ansible-playbooks-3.9.0-0.16.0.git.0.9f19afc.el7.noarch

These /etc/ansible/hosts vars...

openshift_docker_insecure_registries=repo.home.nicknach.net:5000
oreg_url=repo.home.nicknach.net:5000/openshift3/ose-${component}:${version}
openshift_examples_modify_imagestreams=true
ansible_service_broker_image_prefix=repo.home.nicknach.net:5000/openshift3/
ansible_service_broker_image_tag=v3.9.0

produces this result...

2018-01-06 13:14:11 -0600 CST   2018-01-06 13:13:24 -0600 CST   3         controller-manager-25vj4.15074e670ca14f38   Pod         spec.containers{controller-manager}   Warning   Failed                  kubelet, master01.ocp.nicknach.net   Failed to pull image "repo.home.nicknach.net:5000/openshift3/service-catalog:v3.9.0": rpc error: code = Unknown desc = Error: image openshift3/service-catalog:v3.9.0 not found

the image prefix 'ose-' is not being added to the 'service-catalog' pull spec during install.  This needs to be fixed... a work-around is to add a 'service-catalog' tag/alias to that image manifest.

-Nick

Comment 1 Nicholas Schuetz 2018-01-06 20:00:27 UTC
Looks like there is an inconsistency in how the playbook vars are set.

Comparing this...

https://raw.githubusercontent.com/openshift/openshift-ansible/master/roles/ansible_service_broker/vars/openshift-enterprise.yml

to this...

https://github.com/openshift/openshift-ansible/blob/master/roles/openshift_metrics/vars/openshift-enterprise.yml

the new ansible/template service broker openshift-ansible integration is just inconsistent (and possibly incomplete) with the rest of the code base.

A better work-around for this specific issue, is to include 'ose-' at the end of openshift_service_catalog_image_prefix manually.

## Ex:
#openshift_service_catalog_image_prefix=repo.home.nicknach.net:5000/openshift3/ose-

Comment 2 Fabian von Feilitzsch 2018-01-15 19:35:03 UTC
It looks like you manually set "ansible_service_broker_image_prefix" to "repo.home.nicknach.net:5000/openshift3/" (which should not work, it should have a trailing ose-), but then hit an error with the service catalog prefix, which as far as I can tell should still be "registry.access.redhat.com/openshift3/ose-" (https://github.com/openshift/openshift-ansible/blob/9f19afc7529bd7293433b27e834b9ee3479e646f/roles/openshift_service_catalog/vars/openshift-enterprise.yml#L2).

Is the above your full inventory?

Comment 3 Nicholas Schuetz 2018-01-17 00:38:45 UTC
That's exactly my point, why should ALL of the other image_prefix variables include the prefix defined in oreg_url and this one not?

for instance....

##internal image repos
##openshift_additional_repos=[{'id': 'ose-devel', 'name': 'rhaos-3.9', 'baseurl': 'http://repo.home.nicknach.net/repo/rhaos-3.9', 'enabled': 1, 'gpgcheck': 0}]
#openshift_docker_additional_registries=repo.home.nicknach.net:5000
#openshift_docker_insecure_registries=repo.home.nicknach.net:5000
#openshift_docker_blocked_registries=registry.access.redhat.com,docker.io

#oreg_url=repo.home.nicknach.net:5000/openshift3/ose-\${component}:\${version}
#openshift_examples_modify_imagestreams=true

#openshift_cockpit_deployer_prefix=repo.home.nicknach.net:5000/openshift3/

#openshift_metrics_image_prefix=repo.home.nicknach.net:5000/openshift3/
#openshift_metrics_image_version=v3.9.0

#openshift_logging_image_prefix=repo.home.nicknach.net:5000/openshift3/
#openshift_logging_image_version=3.9.0

#openshift_service_catalog_image_prefix=repo.home.nicknach.net:5000/openshift3/ose-
#openshift_service_catalog_image_version=v3.9.0

#ansible_service_broker_image_prefix=repo.home.nicknach.net:5000/openshift3/
#ansible_service_broker_image_tag=v3.9.0
#ansible_service_broker_etcd_image_prefix=repo.home.nicknach.net:5000/openshift3/
#ansible_service_broker_etcd_image_tag=v3.9.0

Comment 4 Nicholas Schuetz 2018-01-17 00:45:32 UTC
Let me filter some of this out for you.... what's wrong with this picture:

oreg_url=repo.home.nicknach.net:5000/openshift3/ose-${component}:${version}
openshift_logging_image_prefix=repo.home.nicknach.net:5000/openshift3/
openshift_metrics_image_prefix=repo.home.nicknach.net:5000/openshift3/
openshift_service_catalog_image_prefix=repo.home.nicknach.net:5000/openshift3/ose-

Comment 6 Scott Dodson 2018-01-22 17:42:21 UTC
Nicholas,

I agree that this is quite the mess. We plan to refactor all of this in the next release to simplify all of these down to the point that oreg_url should need to be the only variable specified to alter the registry that's used while still allowing for more fine grained control.

https://bugzilla.redhat.com/show_bug.cgi?id=1516534
and 
https://github.com/openshift/openshift-ansible/issues/4415

Have some additional discussion on the topic. We'll make this a priority for 3.10.

*** This bug has been marked as a duplicate of bug 1516534 ***


Note You need to log in before you can comment on or make changes to this bug.