openshift-ansible: hosted templates yaml error: control characters are not allowed
Description
On a multi master with separate router and etcd nodes install on EC2,
TASK [openshift_hosted_templates : Create or update hosted templates] **********
fatal: [xxx.xxx.xxx.xxx]: FAILED! => {
"changed": true,
"cmd": [
"/usr/local/bin/oc",
"create",
"-f",
"/etc/origin/hosted",
"--config=/tmp/openshift-ansible-g35TFK/admin.kubeconfig",
"-n",
"openshift"
],
"delta": "0:00:00.277915",
"end": "2017-02-27 11:33:57.246104",
"failed": true,
"failed_when_result": true,
"invocation": {
"module_args": {
"_raw_params": "/usr/local/bin/oc create -f /etc/origin/hosted --config=/tmp/openshift-ansible-g35TFK/admin.kubeconfig -n openshift",
"_uses_shell": false,
"chdir": null,
"creates": null,
"executable": null,
"removes": null,
"warn": true
},
"module_name": "command"
},
"rc": 1,
"start": "2017-02-27 11:33:56.968189",
"warnings": []
}
STDOUT:
template "logging-deployer-account-template" created
template "logging-deployer-template" created
template "metrics-deployer-template" created
template "registry-console" created
STDERR:
yaml: control characters are not allowed
yaml: control characters are not allowed
yaml: control characters are not allowed
Version
openshift v1.4.1+3f9807a
kubernetes v1.4.0+776c994
etcd 3.1.0-rc.0
ansible 2.2.0.0
config file = /Users/bsun/Dropbox/Others/openshift-ansible/ansible.cfg
configured module search path = Default w/o overrides
openshift-ansible-3.4.66-1
Steps To Reproduce
- on fresh instances
- run ansible
ansible-playbook playbooks/aws/openshift-cluster/config.yml -D -e openshift_release='1.4.1' -vvv
Expected Results
Warning message from stdout/stderr are ignored.
Observed Results
Ansible run fails, however the templates created successfully, and re-run ansible doesn’t try to create these templates anymore.
Additional Information
CentOS Linux release 7.3.1611 (Core)
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 23 (6 by maintainers)
I was able to reproduce and fix the problem.
For whoever is using Mac to install the cluster, you can find two files in the
/usr/share/openshift/hosted/both with the._.prefix, please feel free to remove them. as shown by the commandfile ._.*you can see that those have been created by spotlight somehow.If you are still experiencing a problem on the conversion of that registry-console.yaml file AND you do NOT need any examples on your cluster you can safely add:
openshift_install_examples=falseto your inventory, preventing the error to happen again.Cheers, Andrea
I have had the same error running on Mac OSX with the latest version of Ansible. I ended up running the playbook on a VM and it ran fine.
I’m seeing this too. Single master / embedded etcd. VMs were provisioned using a new Centos 7 Minimal ISO.