From 621b18ab7c6d4ae3dd2cc75df98e460ba4be39a4 Mon Sep 17 00:00:00 2001 From: Adisorn Ermongkonchai Date: Thu, 20 Oct 2016 17:56:06 +0000 Subject: [PATCH] update YDK playbooks to reflect new YDK path --- changes.diff | 198 ++++++++++++++++++ local/ansible_env | 5 +- local/common/iosxr_common.pyc | Bin 636 -> 636 bytes local/library/iosxr_show_install_active | 2 +- local/library/iosxr_show_install_committed | 2 +- local/library/iosxr_show_install_inactive | 2 +- local/library/iosxr_show_install_last_log | 2 +- local/library/iosxr_show_install_log | 2 +- local/library/iosxr_show_install_request | 2 +- local/library/iosxr_show_install_version | 2 +- local/samples/ydk/ydk_show_install_active.yml | 2 +- .../ydk/ydk_show_install_committed.yml | 2 +- .../samples/ydk/ydk_show_install_inactive.yml | 2 +- .../samples/ydk/ydk_show_install_last_log.yml | 2 +- local/samples/ydk/ydk_show_install_log.yml | 2 +- .../samples/ydk/ydk_show_install_request.yml | 2 +- .../samples/ydk/ydk_show_install_version.yml | 2 +- 17 files changed, 215 insertions(+), 16 deletions(-) create mode 100644 changes.diff diff --git a/changes.diff b/changes.diff new file mode 100644 index 0000000..e8ae448 --- /dev/null +++ b/changes.diff @@ -0,0 +1,198 @@ +diff --git a/local/ansible_env b/local/ansible_env +index 7f916b9..55e79d7 100644 +--- a/local/ansible_env ++++ b/local/ansible_env +@@ -3,5 +3,6 @@ export IOSXRDIR=$BASEDIR/ansible/iosxr/iosxr-ansible + export ANSIBLE_INVENTORY=$IOSXRDIR/local/ansible_hosts + export ANSIBLE_LIBRARY=$IOSXRDIR/local/library + export ANSIBLE_CONFIG=$IOSXRDIR/local/ansible_cfg +-export YDK_DIR=$BASEDIR/ydk/ydk-py +-export PYTHONPATH=$YDK_DIR:$IOSXRDIR/local/common ++export YDK_DIR=$BASEDIR/ydk-py/cisco-ios-xr ++export YDK_CORE_DIR=$BASEDIR/ydk-py/core ++export PYTHONPATH=$YDK_DIR:$YDK_CORE_DIR:$IOSXRDIR/local/common +diff --git a/local/common/iosxr_common.pyc b/local/common/iosxr_common.pyc +index a98efb5..6890d11 100644 +Binary files a/local/common/iosxr_common.pyc and b/local/common/iosxr_common.pyc differ +diff --git a/local/library/iosxr_show_install_active b/local/library/iosxr_show_install_active +index 11feabb..eaf7a98 100644 +--- a/local/library/iosxr_show_install_active ++++ b/local/library/iosxr_show_install_active +@@ -21,7 +21,7 @@ + from ansible.module_utils.basic import * + from ydk.providers import NetconfServiceProvider + from ydk.services import CRUDService +-from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall ++from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall + + def main(): + module = AnsibleModule( +diff --git a/local/library/iosxr_show_install_committed b/local/library/iosxr_show_install_committed +index 795d67b..5eea3a8 100644 +--- a/local/library/iosxr_show_install_committed ++++ b/local/library/iosxr_show_install_committed +@@ -21,7 +21,7 @@ + from ansible.module_utils.basic import * + from ydk.providers import NetconfServiceProvider + from ydk.services import CRUDService +-from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall ++from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall + + def main(): + module = AnsibleModule( +diff --git a/local/library/iosxr_show_install_inactive b/local/library/iosxr_show_install_inactive +index ef0238f..9ce0367 100644 +--- a/local/library/iosxr_show_install_inactive ++++ b/local/library/iosxr_show_install_inactive +@@ -21,7 +21,7 @@ + from ansible.module_utils.basic import * + from ydk.providers import NetconfServiceProvider + from ydk.services import CRUDService +-from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall ++from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall + + def main(): + module = AnsibleModule( +diff --git a/local/library/iosxr_show_install_last_log b/local/library/iosxr_show_install_last_log +index 4f90e1a..7438ee9 100644 +--- a/local/library/iosxr_show_install_last_log ++++ b/local/library/iosxr_show_install_last_log +@@ -21,7 +21,7 @@ + from ansible.module_utils.basic import * + from ydk.providers import NetconfServiceProvider + from ydk.services import CRUDService +-from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall ++from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall + + def main(): + module = AnsibleModule( +diff --git a/local/library/iosxr_show_install_log b/local/library/iosxr_show_install_log +index b558fe4..5a6c578 100644 +--- a/local/library/iosxr_show_install_log ++++ b/local/library/iosxr_show_install_log +@@ -21,7 +21,7 @@ + from ansible.module_utils.basic import * + from ydk.providers import NetconfServiceProvider + from ydk.services import CRUDService +-from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall ++from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall + + def main(): + module = AnsibleModule( +diff --git a/local/library/iosxr_show_install_request b/local/library/iosxr_show_install_request +index b234401..9bb357e 100644 +--- a/local/library/iosxr_show_install_request ++++ b/local/library/iosxr_show_install_request +@@ -21,7 +21,7 @@ + from ansible.module_utils.basic import * + from ydk.providers import NetconfServiceProvider + from ydk.services import CRUDService +-from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall ++from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall + + def main(): + module = AnsibleModule( +diff --git a/local/library/iosxr_show_install_version b/local/library/iosxr_show_install_version +index f370ef6..635df11 100644 +--- a/local/library/iosxr_show_install_version ++++ b/local/library/iosxr_show_install_version +@@ -21,7 +21,7 @@ + from ansible.module_utils.basic import * + from ydk.providers import NetconfServiceProvider + from ydk.services import CRUDService +-from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall ++from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall + import sys + import logging + +diff --git a/local/samples/ydk/ydk_show_install_active.yml b/local/samples/ydk/ydk_show_install_active.yml +index e317a21..889d4d3 100644 +--- a/local/samples/ydk/ydk_show_install_active.yml ++++ b/local/samples/ydk/ydk_show_install_active.yml +@@ -4,7 +4,7 @@ + gather_facts: no + + vars: +- - ansible_ssh_pass: 'lab' ++ - ansible_ssh_pass: 'cisco' + + tasks: + - iosxr_show_install_active: +diff --git a/local/samples/ydk/ydk_show_install_committed.yml b/local/samples/ydk/ydk_show_install_committed.yml +index 0d1dd98..c79702f 100644 +--- a/local/samples/ydk/ydk_show_install_committed.yml ++++ b/local/samples/ydk/ydk_show_install_committed.yml +@@ -4,7 +4,7 @@ + gather_facts: no + + vars: +- - ansible_ssh_pass: 'lab' ++ - ansible_ssh_pass: 'cisco' + + tasks: + - iosxr_show_install_committed: +diff --git a/local/samples/ydk/ydk_show_install_inactive.yml b/local/samples/ydk/ydk_show_install_inactive.yml +index 3c47b2a..276daa0 100644 +--- a/local/samples/ydk/ydk_show_install_inactive.yml ++++ b/local/samples/ydk/ydk_show_install_inactive.yml +@@ -4,7 +4,7 @@ + gather_facts: no + + vars: +- - ansible_ssh_pass: 'lab' ++ - ansible_ssh_pass: 'cisco' + + tasks: + - iosxr_show_install_inactive: +diff --git a/local/samples/ydk/ydk_show_install_last_log.yml b/local/samples/ydk/ydk_show_install_last_log.yml +index fc7cf9a..1b288ff 100644 +--- a/local/samples/ydk/ydk_show_install_last_log.yml ++++ b/local/samples/ydk/ydk_show_install_last_log.yml +@@ -4,7 +4,7 @@ + gather_facts: no + + vars: +- - ansible_ssh_pass: 'lab' ++ - ansible_ssh_pass: 'cisco' + + tasks: + - iosxr_show_install_last_log: +diff --git a/local/samples/ydk/ydk_show_install_log.yml b/local/samples/ydk/ydk_show_install_log.yml +index 172586e..704acea 100644 +--- a/local/samples/ydk/ydk_show_install_log.yml ++++ b/local/samples/ydk/ydk_show_install_log.yml +@@ -4,7 +4,7 @@ + gather_facts: no + + vars: +- - ansible_ssh_pass: 'lab' ++ - ansible_ssh_pass: 'cisco' + + tasks: + - iosxr_show_install_log: +diff --git a/local/samples/ydk/ydk_show_install_request.yml b/local/samples/ydk/ydk_show_install_request.yml +index a8ff199..7282c0a 100644 +--- a/local/samples/ydk/ydk_show_install_request.yml ++++ b/local/samples/ydk/ydk_show_install_request.yml +@@ -4,7 +4,7 @@ + gather_facts: no + + vars: +- - ansible_ssh_pass: 'lab' ++ - ansible_ssh_pass: 'cisco' + + tasks: + - iosxr_show_install_request: +diff --git a/local/samples/ydk/ydk_show_install_version.yml b/local/samples/ydk/ydk_show_install_version.yml +index 2077c72..df7801e 100644 +--- a/local/samples/ydk/ydk_show_install_version.yml ++++ b/local/samples/ydk/ydk_show_install_version.yml +@@ -4,7 +4,7 @@ + gather_facts: no + + vars: +- - ansible_ssh_pass: 'lab' ++ - ansible_ssh_pass: 'cisco' + + tasks: + - iosxr_show_install_version: diff --git a/local/ansible_env b/local/ansible_env index 7f916b9..55e79d7 100644 --- a/local/ansible_env +++ b/local/ansible_env @@ -3,5 +3,6 @@ export IOSXRDIR=$BASEDIR/ansible/iosxr/iosxr-ansible export ANSIBLE_INVENTORY=$IOSXRDIR/local/ansible_hosts export ANSIBLE_LIBRARY=$IOSXRDIR/local/library export ANSIBLE_CONFIG=$IOSXRDIR/local/ansible_cfg -export YDK_DIR=$BASEDIR/ydk/ydk-py -export PYTHONPATH=$YDK_DIR:$IOSXRDIR/local/common +export YDK_DIR=$BASEDIR/ydk-py/cisco-ios-xr +export YDK_CORE_DIR=$BASEDIR/ydk-py/core +export PYTHONPATH=$YDK_DIR:$YDK_CORE_DIR:$IOSXRDIR/local/common diff --git a/local/common/iosxr_common.pyc b/local/common/iosxr_common.pyc index a98efb57b3264f8a81561628ce00b10e8976a134..6890d11e5bbb8fb74eb5c74e46dee86c94ccc8c0 100644 GIT binary patch delta 35 pcmeyv@`r_k`7aMvkkDj2x5iF;3=YV_;w?W&#pCOaQ?;2w?yK diff --git a/local/library/iosxr_show_install_active b/local/library/iosxr_show_install_active index 11feabb..eaf7a98 100644 --- a/local/library/iosxr_show_install_active +++ b/local/library/iosxr_show_install_active @@ -21,7 +21,7 @@ from ansible.module_utils.basic import * from ydk.providers import NetconfServiceProvider from ydk.services import CRUDService -from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall +from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall def main(): module = AnsibleModule( diff --git a/local/library/iosxr_show_install_committed b/local/library/iosxr_show_install_committed index 795d67b..5eea3a8 100644 --- a/local/library/iosxr_show_install_committed +++ b/local/library/iosxr_show_install_committed @@ -21,7 +21,7 @@ from ansible.module_utils.basic import * from ydk.providers import NetconfServiceProvider from ydk.services import CRUDService -from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall +from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall def main(): module = AnsibleModule( diff --git a/local/library/iosxr_show_install_inactive b/local/library/iosxr_show_install_inactive index ef0238f..9ce0367 100644 --- a/local/library/iosxr_show_install_inactive +++ b/local/library/iosxr_show_install_inactive @@ -21,7 +21,7 @@ from ansible.module_utils.basic import * from ydk.providers import NetconfServiceProvider from ydk.services import CRUDService -from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall +from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall def main(): module = AnsibleModule( diff --git a/local/library/iosxr_show_install_last_log b/local/library/iosxr_show_install_last_log index 4f90e1a..7438ee9 100644 --- a/local/library/iosxr_show_install_last_log +++ b/local/library/iosxr_show_install_last_log @@ -21,7 +21,7 @@ from ansible.module_utils.basic import * from ydk.providers import NetconfServiceProvider from ydk.services import CRUDService -from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall +from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall def main(): module = AnsibleModule( diff --git a/local/library/iosxr_show_install_log b/local/library/iosxr_show_install_log index b558fe4..5a6c578 100644 --- a/local/library/iosxr_show_install_log +++ b/local/library/iosxr_show_install_log @@ -21,7 +21,7 @@ from ansible.module_utils.basic import * from ydk.providers import NetconfServiceProvider from ydk.services import CRUDService -from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall +from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall def main(): module = AnsibleModule( diff --git a/local/library/iosxr_show_install_request b/local/library/iosxr_show_install_request index b234401..9bb357e 100644 --- a/local/library/iosxr_show_install_request +++ b/local/library/iosxr_show_install_request @@ -21,7 +21,7 @@ from ansible.module_utils.basic import * from ydk.providers import NetconfServiceProvider from ydk.services import CRUDService -from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall +from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall def main(): module = AnsibleModule( diff --git a/local/library/iosxr_show_install_version b/local/library/iosxr_show_install_version index f370ef6..635df11 100644 --- a/local/library/iosxr_show_install_version +++ b/local/library/iosxr_show_install_version @@ -21,7 +21,7 @@ from ansible.module_utils.basic import * from ydk.providers import NetconfServiceProvider from ydk.services import CRUDService -from ydk.models.spirit.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall +from ydk.models.cisco_ios_xr.Cisco_IOS_XR_spirit_install_instmgr_oper import SoftwareInstall import sys import logging diff --git a/local/samples/ydk/ydk_show_install_active.yml b/local/samples/ydk/ydk_show_install_active.yml index e317a21..889d4d3 100644 --- a/local/samples/ydk/ydk_show_install_active.yml +++ b/local/samples/ydk/ydk_show_install_active.yml @@ -4,7 +4,7 @@ gather_facts: no vars: - - ansible_ssh_pass: 'lab' + - ansible_ssh_pass: 'cisco' tasks: - iosxr_show_install_active: diff --git a/local/samples/ydk/ydk_show_install_committed.yml b/local/samples/ydk/ydk_show_install_committed.yml index 0d1dd98..c79702f 100644 --- a/local/samples/ydk/ydk_show_install_committed.yml +++ b/local/samples/ydk/ydk_show_install_committed.yml @@ -4,7 +4,7 @@ gather_facts: no vars: - - ansible_ssh_pass: 'lab' + - ansible_ssh_pass: 'cisco' tasks: - iosxr_show_install_committed: diff --git a/local/samples/ydk/ydk_show_install_inactive.yml b/local/samples/ydk/ydk_show_install_inactive.yml index 3c47b2a..276daa0 100644 --- a/local/samples/ydk/ydk_show_install_inactive.yml +++ b/local/samples/ydk/ydk_show_install_inactive.yml @@ -4,7 +4,7 @@ gather_facts: no vars: - - ansible_ssh_pass: 'lab' + - ansible_ssh_pass: 'cisco' tasks: - iosxr_show_install_inactive: diff --git a/local/samples/ydk/ydk_show_install_last_log.yml b/local/samples/ydk/ydk_show_install_last_log.yml index fc7cf9a..1b288ff 100644 --- a/local/samples/ydk/ydk_show_install_last_log.yml +++ b/local/samples/ydk/ydk_show_install_last_log.yml @@ -4,7 +4,7 @@ gather_facts: no vars: - - ansible_ssh_pass: 'lab' + - ansible_ssh_pass: 'cisco' tasks: - iosxr_show_install_last_log: diff --git a/local/samples/ydk/ydk_show_install_log.yml b/local/samples/ydk/ydk_show_install_log.yml index 172586e..704acea 100644 --- a/local/samples/ydk/ydk_show_install_log.yml +++ b/local/samples/ydk/ydk_show_install_log.yml @@ -4,7 +4,7 @@ gather_facts: no vars: - - ansible_ssh_pass: 'lab' + - ansible_ssh_pass: 'cisco' tasks: - iosxr_show_install_log: diff --git a/local/samples/ydk/ydk_show_install_request.yml b/local/samples/ydk/ydk_show_install_request.yml index a8ff199..7282c0a 100644 --- a/local/samples/ydk/ydk_show_install_request.yml +++ b/local/samples/ydk/ydk_show_install_request.yml @@ -4,7 +4,7 @@ gather_facts: no vars: - - ansible_ssh_pass: 'lab' + - ansible_ssh_pass: 'cisco' tasks: - iosxr_show_install_request: diff --git a/local/samples/ydk/ydk_show_install_version.yml b/local/samples/ydk/ydk_show_install_version.yml index 2077c72..df7801e 100644 --- a/local/samples/ydk/ydk_show_install_version.yml +++ b/local/samples/ydk/ydk_show_install_version.yml @@ -4,7 +4,7 @@ gather_facts: no vars: - - ansible_ssh_pass: 'lab' + - ansible_ssh_pass: 'cisco' tasks: - iosxr_show_install_version: