From b5613b96f2879590b5fe0e16886198b3fc809599 Mon Sep 17 00:00:00 2001 From: Manuel Buil Date: Tue, 14 Aug 2018 15:46:07 +0200 Subject: [PATCH] Replace install_method by odl_install_method install_method is too general and might clash with variables from other playbooks in complex systems. This is happening in openstack-ansible Change-Id: Ida8ad8f1fc04c619a9e04a103d3df520cf57fb88 Signed-off-by: Manuel Buil --- README.markdown | 4 ++-- examples/deb_path.yml | 2 +- examples/deb_repo.yml | 2 +- examples/rpm_path.yml | 2 +- tasks/install_odl.yml | 8 ++++---- vars/main.yml | 12 ++++++------ 6 files changed, 15 insertions(+), 15 deletions(-) diff --git a/README.markdown b/README.markdown index 097f351..3676f7c 100644 --- a/README.markdown +++ b/README.markdown @@ -59,8 +59,8 @@ The Ansible role will handle opening this port in FirewallD if it's active. ### Install Method OpenDaylight can be installed either via an RPM or a .deb depending on the operating system. -For RedHat based OSs, the valid options for `install_method` are `rpm_repo` or `rpm_path`. -For Debian based OSs, `install_method` can accept either `deb_repo` or `deb_path`. +For RedHat based OSs, the valid options for `odl_install_method` are `rpm_repo` or `rpm_path`. +For Debian based OSs, `odl_install_method` can accept either `deb_repo` or `deb_path`. ## Installing OpenDaylight diff --git a/examples/deb_path.yml b/examples/deb_path.yml index d8a6dd6..052795c 100644 --- a/examples/deb_path.yml +++ b/examples/deb_path.yml @@ -5,4 +5,4 @@ - role: opendaylight # Install ODL from a local/remote .deb path. Not including # this causes the install to use a repo for the RPM. - install_method: "deb_path" + odl_install_method: "deb_path" diff --git a/examples/deb_repo.yml b/examples/deb_repo.yml index 923a8d8..395fa75 100644 --- a/examples/deb_repo.yml +++ b/examples/deb_repo.yml @@ -5,4 +5,4 @@ - role: opendaylight # Install ODL from a Debian repo. Not including this # causes the install to use a repo for the RPM. - install_method: "deb_repo" + odl_install_method: "deb_repo" diff --git a/examples/rpm_path.yml b/examples/rpm_path.yml index f09db9e..3205f89 100644 --- a/examples/rpm_path.yml +++ b/examples/rpm_path.yml @@ -5,6 +5,6 @@ - role: opendaylight # Install from a local/remote path to an ODL RPM. Not including this # causes the install to use a repo for the RPM, which is recommended. - install_method: "rpm_path" + odl_install_method: "rpm_path" # Accept default (local/remote) path to ODL RPM # rpm_path: "" diff --git a/tasks/install_odl.yml b/tasks/install_odl.yml index 0f7068f..c5dc286 100755 --- a/tasks/install_odl.yml +++ b/tasks/install_odl.yml @@ -9,24 +9,24 @@ - include_tasks: install_odl_via_deb_repo.yml when: - ansible_os_family == "Debian" - - install_method == "deb_repo" + - odl_install_method == "deb_repo" # Install ODL using .deb URL or local path to a .deb file - include_tasks: install_odl_via_deb_path.yml when: - ansible_os_family == "Debian" - - install_method == "deb_path" + - odl_install_method == "deb_path" # Install ODL using Yum repo config - include_tasks: install_odl_via_rpm_repo.yml when: - (ansible_os_family == "RedHat") or (ansible_os_family == "Suse") - - install_method == "rpm_repo" + - odl_install_method == "rpm_repo" # Install ODL using rpm URL or a local path to a rpm file - include_tasks: install_odl_via_rpm_path.yml when: - (ansible_os_family == "RedHat") or (ansible_os_family == "Suse") - - install_method == "rpm_path" + - odl_install_method == "rpm_path" diff --git a/vars/main.yml b/vars/main.yml index 65c2423..f3fcff1 100755 --- a/vars/main.yml +++ b/vars/main.yml @@ -58,7 +58,7 @@ akka_remoting_port: 2550 # rpm_path: Install ODL rpm from a local path or remote URL # dep_repo: Install ODL using a debian repository # deb_path: Install ODL .deb from a local path or remote URL -install_method: "rpm_repo" +odl_install_method: "rpm_repo" # We need this dictionary to translate from ODL version to the version number odl_version_dict: @@ -68,12 +68,12 @@ odl_version_dict: nitrogen: 7 # URL of the .repo config to use when installing ODL from a repo -# NB: This will only take effect when `install_method` is "rpm_repo" +# NB: This will only take effect when `odl_install_method` is "rpm_repo" rpm_repo_url: "{% if 'latest_release' not in odl_version %}https://git.opendaylight.org/gerrit/gitweb?p=integration/packaging.git;a=blob_plain;f=packages/rpm/example_repo_configs/opendaylight-{{ odl_version_dict[odl_version] }}-devel.repo{% else %}https://git.opendaylight.org/gerrit/gitweb?p=integration/packaging.git;a=blob_plain;f=packages/rpm/example_repo_configs/opendaylight-8-release.repo{% endif %}" suse_rpm_repo_url: "{% if 'latest_release' not in odl_version %}https://git.opendaylight.org/gerrit/gitweb?p=integration/packaging.git;a=blob_plain;f=packages/rpm/example_repo_configs/opendaylight-{{ odl_version_dict[odl_version] }}-opensuse-devel.repo{% else %}https://download.opensuse.org/repositories/Virtualization:/NFV/openSUSE_Leap_42.3/{% endif %}" # URL of the deb repository to use when installing ODL from a repo -# NB: This will only take effect when `install_method` is "deb_repo" +# NB: This will only take effect when `odl_install_method` is "deb_repo" # TODO: When deb snaps are built, point to a repo like rpm deb_repo_url: "deb http://ppa.launchpad.net/odl-team/oxygen/ubuntu {{ ansible_lsb.codename }} main" @@ -81,7 +81,7 @@ deb_repo_url: "deb http://ppa.launchpad.net/odl-team/oxygen/ubuntu {{ ansible_ls # `name` param docs: "You can also pass a url or a local path to a rpm file." # See: http://docs.ansible.com/ansible/yum_module.html # NB: Local paths must be relative the host being configured (think `/vagrant`) -# NB: This will only take effect when `install_method` is "rpm_path" +# NB: This will only take effect when `odl_install_method` is "rpm_path" # Default to the release RPM hosted on the CentOS Community Build System rpm_path: "http://cbs.centos.org/repos/nfv7-opendaylight-82-release/x86_64/os/Packages/opendaylight-8.2.0-1.el7.noarch.rpm" # Default to the Nitrogen RPM hosted on the openSUSE OBS @@ -91,7 +91,7 @@ suse_rpm_path: "https://download.opensuse.org/repositories/Virtualization:/NFV/o # `deb` param docs: "Path to a .deb package on the remote machine. If :// in the path, # ansible will attempt to download deb before installing." # See: http://docs.ansible.com/ansible/apt_module.html -# This is used when `install_method` is "deb_path" +# This is used when `odl_install_method` is "deb_path" deb_path: "" # Distro on which quagga packages to be installed @@ -136,4 +136,4 @@ quagga: false # Default ODL user credentials odl_nb_username: admin -odl_nb_password: admin \ No newline at end of file +odl_nb_password: admin -- 2.36.6