Repository: openshift/openshift-ansible

Issue #6086: TASK [template_service_broker : Reconcile with RBAC file] fails
Created: 2017-11-10T10:26:12Z
Description
Provide a brief description of your issue here.
On a RHEL 7.4 machine, running
ansible-playbook -i ansible-inventory /mnt/tests/OpenShift/Origin/install/dist/openshift-ansible/playbooks/byo/config.yml

fails.
Version
Please put the following version information in the code block
indicated below.

Your ansible version per ansible --version

ansible 2.4.0.0
  config file = /etc/ansible/ansible.cfg
  configured module search path = [u'/root/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python2.7/site-packages/ansible
  executable location = /usr/bin/ansible
  python version = 2.7.5 (default, May  3 2017, 07:55:04) [GCC 4.8.5 20150623 (Red Hat 4.8.5-14)]

If you're operating from a git clone:

The output of git describe

openshift-ansible-3.7.5-1-4-g34dfb0d

If you're running from playbooks installed via RPM or
atomic-openshift-utils

The output of rpm -q atomic-openshift-utils openshift-ansible

Place the output between the code block below:
N/A
Steps To Reproduce

ansible-playbook -i ansible-inventory /mnt/tests/OpenShift/Origin/install/dist/openshift-ansible/playbooks/byo/config.yml

Expected Results
Describe what you expected to happen.
No error, ansible-playbook passing and all-on-one OpenShift setup created.
Observed Results
Describe what is actually happening.
TASK [template_service_broker : Set default image variables based on deployment type] ***
ok: [master.example.com] => (item=/mnt/tests/OpenShift/Origin/install/dist/openshift-ansible/roles/template_service_broker/vars/default_images.yml)

TASK [template_service_broker : set template_service_broker facts] *************
ok: [master.example.com]

TASK [template_service_broker : oc_project] ************************************
changed: [master.example.com]

TASK [template_service_broker : command] ***************************************
ok: [master.example.com]

TASK [template_service_broker : copy] ******************************************
changed: [master.example.com] => (item=apiserver-template.yaml)
changed: [master.example.com] => (item=rbac-template.yaml)
changed: [master.example.com] => (item=template-service-broker-registration.yaml)
changed: [master.example.com] => (item=apiserver-config.yaml)

TASK [template_service_broker : yedit] *****************************************
ok: [master.example.com]

TASK [template_service_broker : slurp] *****************************************
ok: [master.example.com]

TASK [template_service_broker : Apply template file] ***************************
changed: [master.example.com]

TASK [template_service_broker : Reconcile with RBAC file] **********************
fatal: [master.example.com]: FAILED! => {"changed": true, "cmd": "oc process -f \"/tmp/tsb-ansible-KmuHhc/rbac-template.yaml\" | oc auth reconcile -f -", "delta": "0:00:00.700965", "end": "2017-11-09 22:50:01.727255", "failed": true, "msg": "non-zero return code", "rc": 1, "start": "2017-11-09 22:50:01.026290", "stderr": "Error: unknown shorthand flag: 'f' in -f\n\n\nUsage:\n  oc auth [options]\n\nAvailable Commands:\n  can-i       Check whether an action is allowed\n\nUse \"oc <command> --help\" for more information about a given command.\nUse \"oc options\" for a list of global command-line options (applies to all commands).", "stderr_lines": ["Error: unknown shorthand flag: 'f' in -f", "", "", "Usage:", "  oc auth [options]", "", "Available Commands:", "  can-i       Check whether an action is allowed", "", "Use \"oc <command> --help\" for more information about a given command.", "Use \"oc options\" for a list of global command-line options (applies to all commands)."], "stdout": "", "stdout_lines": []}
	to retry, use: --limit @/mnt/tests/OpenShift/Origin/install/dist/openshift-ansible/playbooks/byo/config.retry

PLAY RECAP *********************************************************************
master.example.com : ok=624  changed=263  unreachable=0    failed=1   
localhost                  : ok=12   changed=0    unreachable=0    failed=0   


INSTALLER STATUS ***************************************************************
Initialization             : Complete
Health Check               : Complete
etcd Install               : Complete
Master Install             : Complete
Master Additional Install  : Complete
Node Install               : Complete
Hosted Install             : Complete
Service Catalog Install    : In Progress
	This phase can be restarted by running: playbooks/byo/openshift-cluster/service-catalog.yml



Failure summary:


  1. Hosts:    master.example.com
     Play:     Service Catalog
     Task:     Reconcile with RBAC file
     Message:  non-zero return code

For long output or logs, consider using a gist
Additional Information
Provide any additional information which may help us diagnose the
issue.

Your operating system and version, ie: RHEL 7.2, Fedora 23 ($ cat /etc/redhat-release)

Red Hat Enterprise Linux Server release 7.4 (Maipo)


Your inventory file (especially any non-standard configuration parameters)

[OSEv3:children]
masters
nodes

[OSEv3:vars]
ansible_ssh_user=root
deployment_type=origin
openshift_disable_check=memory_availability,docker_storage,disk_availability,package_version

osm_cluster_network_cidr=10.128.0.0/14
openshift_portal_net=172.30.0.0/16
osm_host_subnet_length=9

openshift_router_selector='node-router=true'
openshift_registry_selector='node-registry=true'

openshift_master_identity_providers=[{'name': 'allow_all', 'login': 'true', 'challenge': 'true', 'kind': 'AllowAllPasswordIdentityProvider'}]

[masters]
master.example.com

[etcd]
master.example.com

[nodes]
master.example.com openshift_schedulable=true openshift_node_labels="{ 'node-router': 'true', 'node-registry': 'true', 'node-app': 'true' }"


Sample code, etc

The failure started to show up on 2017-11-09 morning and is determinstic. Previous runs up until 2017-11-07 evening were passing.

Duplicate issue #6135: Failed to reconcile with RBAC file
Created: 2017-11-16T09:27:37Z
Description
TASK [template_service_broker : Reconcile with RBAC file] *********************************************************************************************************************************************************
Thursday 16 November 2017  17:15:25 +0800 (0:00:04.932)       0:11:09.874 *****
fatal: [master.example.com]: FAILED! => {"changed": true, "cmd": "oc process -f "/tmp/tsb-ansible-n886G5/rbac-template.yaml" | oc auth reconcile -f -", "delta": "0:00:01.794441", "end": "2017-11-16 17:15:27.717141", "failed": true, "msg": "non-zero return code", "rc": 1, "start": "2017-11-16 17:15:25.922700", "stderr": "Error: unknown shorthand flag: 'f' in -f\n\n\nUsage:\n  oc auth [options]\n\nAvailable Commands:\n  can-i       Check whether an action is allowed\n\nUse "oc  --help" for more information about a given command.\nUse "oc options" for a list of global command-line options (applies to all commands).", "stderr_lines": ["Error: unknown shorthand flag: 'f' in -f", "", "", "Usage:", "  oc auth [options]", "", "Available Commands:", "  can-i       Check whether an action is allowed", "", "Use "oc  --help" for more information about a given command.", "Use "oc options" for a list of global command-line options (applies to all commands)."], "stdout": "", "stdout_lines": []}
Version
latest
Additional Information
EXTRA INFORMATION GOES HERE

Closing comment (2017-11-16T23:42:46Z): Oops this seems to be duplicate of #6086.