Bug 1708568 - scaleup hosts will fail at TASK [Get release image] if openshift_kubeconfig_path="~/.kube/config"
Summary: scaleup hosts will fail at TASK [Get release image] if openshift_kubeconfig_p...
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
: 4.1.0
Assignee: Russell Teague
QA Contact: Weihua Meng
Depends On:
TreeView+ depends on / blocked
Reported: 2019-05-10 08:47 UTC by Weihua Meng
Modified: 2019-06-04 10:48 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: The openshift client 'oc' does not support tilde '~' in kube config paths. Consequence: 'oc' would fail to load the kube config using the default path provided '~/.kube/config' Fix: An additional filter was added to convert user home paths to full paths before passing to 'oc' Result: 'oc' is able to load the kube config from user home and default paths.
Clone Of:
: 1708588 (view as bug list)
Last Closed: 2019-06-04 10:48:39 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:0758 0 None None None 2019-06-04 10:48:47 UTC

Description Weihua Meng 2019-05-10 08:47:37 UTC
Description of problem:
scaleup hosts will fail at TASK [Get release image] if openshift_kubeconfig_path="~/.kube/config"

Root Cause: https://bugzilla.redhat.com/show_bug.cgi?id=1231760

Version-Release number of the following components:

How reproducible:

Steps to Reproduce:
1. run ansible playbooks with openshift_kubeconfig_path="~/.kube/config" in inventory host file.

Actual results:

fatal: [dell-r730-068.dsal.lab.eng.rdu2.redhat.com -> localhost]: FAILED! => {
    "attempts": 36,
    "changed": true,
    "cmd": [
    "delta": "0:00:00.106092",
    "end": "2019-05-10 02:04:01.909090",
    "invocation": {
        "module_args": {
            "_raw_params": "oc get clusterversion --config=~/.kube/config --output=jsonpath='{.items[0].status.desired.image}'",
            "_uses_shell": false,
            "argv": null,
            "chdir": null,
            "creates": null,
            "executable": null,
            "removes": null,
            "stdin": null,
            "warn": true
    "msg": "non-zero return code",
    "rc": 1,
    "start": "2019-05-10 02:04:01.802998",
    "stderr": "error: stat ~/.kube/config: no such file or directory",
    "stderr_lines": [
        "error: stat ~/.kube/config: no such file or directory"
    "stdout": "",
    "stdout_lines": []

Expected results:
ansible playbook finish successfully.

Additional info: 
$ oc get clusterversion --config ~/.kube/config
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.1.0-0.nightly-2019-05-09-204138   True        True          2m50s   Unable to apply 4.1.0-0.nightly-2019-05-09-204138: the image may not be safe to use

$ oc get clusterversion --config=~/.kube/config
error: stat ~/.kube/config: no such file or directory

use absolute path

Comment 6 Weihua Meng 2019-05-13 02:01:08 UTC


Comment 8 errata-xmlrpc 2019-06-04 10:48:39 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.


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