Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1509782 - openshift_prometheus_image_prefix did not use the default value if not set it in inventory
Summary: openshift_prometheus_image_prefix did not use the default value if not set it...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer
Version: 3.7.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 3.7.0
Assignee: Michael Gugino
QA Contact: Junqi Zhao
URL:
Whiteboard: aos-scalability-37
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-11-06 03:28 UTC by Junqi Zhao
Modified: 2017-11-28 22:21 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-11-28 22:21:49 UTC


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2017:3188 normal SHIPPED_LIVE Moderate: Red Hat OpenShift Container Platform 3.7 security, bug, and enhancement update 2017-11-29 02:34:54 UTC

Description Junqi Zhao 2017-11-06 03:28:41 UTC
Description of problem:
Did not set openshift_prometheus_image_prefix in inventory file and deployed prometheus, job failed at 'openshift_prometheus_image_prefix' is undefined", it did not take the default value "registry.access.redhat.com/openshift3/".

Error:
********************************************************************************
fatal: [host-8-242-139.host.centralci.eng.rdu2.redhat.com]: FAILED! => {
    "failed": true, 
    "msg": "The task includes an option with an undefined variable. The error was: 'openshift_prometheus_image_prefix' is undefined\n\nThe error appears to have been in '/usr/share/ansible/openshift-ansible/roles/openshift_prometheus/tasks/main.yaml': line 8, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n- name: Set image facts\n  ^ here\n\nexception type: <class 'ansible.errors.AnsibleUndefinedVariable'>\nexception: 'openshift_prometheus_image_prefix' is undefined"
}
	to retry, use: --limit @/usr/share/ansible/openshift-ansible/playbooks/byo/openshift-cluster/openshift-prometheus.retry
********************************************************************************

Version-Release number of the following components:
# rpm -qa | grep openshift-ansible
openshift-ansible-lookup-plugins-3.7.0-0.191.0.git.0.bc2ff60.el7.noarch
openshift-ansible-playbooks-3.7.0-0.191.0.git.0.bc2ff60.el7.noarch
openshift-ansible-filter-plugins-3.7.0-0.191.0.git.0.bc2ff60.el7.noarch
openshift-ansible-callback-plugins-3.7.0-0.191.0.git.0.bc2ff60.el7.noarch
openshift-ansible-roles-3.7.0-0.191.0.git.0.bc2ff60.el7.noarch
openshift-ansible-docs-3.7.0-0.191.0.git.0.bc2ff60.el7.noarch
openshift-ansible-3.7.0-0.191.0.git.0.bc2ff60.el7.noarch

images:
prometheus-alert-buffer/images/v3.7.0-0.194.0.0
prometheus-alertmanager/images/v3.7.0-0.194.0.0
oauth-proxy/images/v3.7.0-0.194.0.0
prometheus/images/v3.7.0-0.194.0.0

How reproducible:
Always

Steps to Reproduce:
1. Deploy prometheus, inventory file see the [Additional info] part
2.
3.

Actual results:
Throw out errof 'openshift_prometheus_image_prefix' is undefined"

Expected results:
Should not be error throw out

Additional info:
[OSEv3:children]
masters
etcd


[masters]
${MASTER} openshift_public_hostname=${MASTER}

[etcd]
${ETCD} openshift_public_hostname=${ETCD}



[OSEv3:vars]
ansible_ssh_user=root
ansible_ssh_private_key_file="~/libra.pem"
deployment_type=openshift-enterprise

# prometheus
openshift_prometheus_state=present
openshift_prometheus_namespace=prometheus

openshift_prometheus_replicas=1
openshift_prometheus_node_selector={'role': 'node'}

Comment 1 Michael Gugino 2017-11-07 18:21:09 UTC
PR Created: https://github.com/openshift/openshift-ansible/pull/6036

Comment 3 Junqi Zhao 2017-11-08 01:55:06 UTC
We need new openshift-ansible build to verify this defect, the latest openshift-ansible version is openshift-ansible-3.7.0-0.197.0, it does not contain the fix.

But I used packages from master branch, issue is fixed.
Will verify this defect when we get the openshift-ansible packages contain this fix.

Comment 4 Xiaoli Tian 2017-11-09 03:22:59 UTC
Please test it on build 3.7.4-1 or newer version.

Comment 5 Junqi Zhao 2017-11-09 05:40:22 UTC
openshift_prometheus_image_prefix would use the default value "registry.access.redhat.com/openshift3/"  if not set it in inventory, no error threw out during the deployment.


# rpm -qa | grep openshift-ansible
openshift-ansible-playbooks-3.7.4-1.git.0.254e849.el7.noarch
openshift-ansible-filter-plugins-3.7.4-1.git.0.254e849.el7.noarch
openshift-ansible-lookup-plugins-3.7.4-1.git.0.254e849.el7.noarch
openshift-ansible-callback-plugins-3.7.4-1.git.0.254e849.el7.noarch
openshift-ansible-3.7.4-1.git.0.254e849.el7.noarch
openshift-ansible-roles-3.7.4-1.git.0.254e849.el7.noarch
openshift-ansible-docs-3.7.4-1.git.0.254e849.el7.noarch

# openshift version
openshift v3.7.0-0.198.0
kubernetes v1.7.6+a08f5eeb62
etcd 3.2.8

Comment 8 errata-xmlrpc 2017-11-28 22:21:49 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/RHSA-2017:3188


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