Browse Source

Package the default ansible.cfg with atomic-openshift-utils.

If this file exists on disk, the installer will use it if the user didn't
specify an ansible config file on the CLI.

Rename share directory to match the rpm name. (utils vs util)
Devan Goodwin 9 years ago
parent
commit
c2f3f81d92
2 changed files with 4 additions and 1 deletions
  1. 3 0
      openshift-ansible.spec
  2. 1 1
      utils/src/ooinstall/cli_installer.py

+ 3 - 0
openshift-ansible.spec

@@ -82,6 +82,8 @@ pushd utils
 %{__python} setup.py install --skip-build --root %{buildroot}
 # Remove this line once the name change has happened
 mv -f %{buildroot}%{_bindir}/oo-install %{buildroot}%{_bindir}/atomic-openshift-installer
+mkdir -p %{buildroot}%{_datadir}/atomic-openshift-utils/
+cp etc/ansible.cfg %{buildroot}%{_datadir}/atomic-openshift-utils/ansible.cfg
 popd
 
 # Base openshift-ansible files
@@ -252,6 +254,7 @@ Atomic OpenShift Utilities includes
 %files -n atomic-openshift-utils
 %{python_sitelib}/ooinstall*
 %{_bindir}/atomic-openshift-installer
+%{_datadir}/atomic-openshift-utils/ansible.cfg
 
 
 %changelog

+ 1 - 1
utils/src/ooinstall/cli_installer.py

@@ -11,7 +11,7 @@ from ooinstall import OOConfig
 from ooinstall.oo_config import Host
 from ooinstall.variants import find_variant, get_variant_version_combos
 
-DEFAULT_ANSIBLE_CONFIG = '/usr/share/atomic-openshift-util/ansible.cfg'
+DEFAULT_ANSIBLE_CONFIG = '/usr/share/atomic-openshift-utils/ansible.cfg'
 DEFAULT_PLAYBOOK_DIR = '/usr/share/ansible/openshift-ansible/'
 
 def validate_ansible_dir(path):