summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Wiebe <mwiebe@cisco.com>2018-02-16 23:50:31 -0500
committerTrishna Guha <trishnaguha17@gmail.com>2018-02-17 10:20:31 +0530
commit6e096cb0c94cc69d3df653dbc564df0eafc1f9e4 (patch)
tree1612143de99d0add4c52d147a99458eea16188c8
parente24c547a3a810e6d4496f96845dcd8c3a2aad2c0 (diff)
downloadansible-6e096cb0c94cc69d3df653dbc564df0eafc1f9e4.tar.gz
Remove kickstart_image_required check (#36319)
-rw-r--r--lib/ansible/modules/network/nxos/nxos_install_os.py16
1 files changed, 1 insertions, 15 deletions
diff --git a/lib/ansible/modules/network/nxos/nxos_install_os.py b/lib/ansible/modules/network/nxos/nxos_install_os.py
index 21d1f2c8c2..3b87b5403d 100644
--- a/lib/ansible/modules/network/nxos/nxos_install_os.py
+++ b/lib/ansible/modules/network/nxos/nxos_install_os.py
@@ -60,6 +60,7 @@ options:
kickstart_image_file:
description:
- Name of the kickstart image file on flash.
+ (Not required on all Nexus platforms)
required: false
default: null
issu:
@@ -181,17 +182,6 @@ def get_platform(module):
return type
-def kickstart_image_required(module):
- '''Determine if platform requires a kickstart image'''
- data = execute_show_command(module, 'show version')[0]
- kickstart_required = False
- for x in data.split('\n'):
- if re.search(r'kickstart image file is:', x):
- kickstart_required = True
-
- return kickstart_required
-
-
def parse_show_install(data):
"""Helper method to parse the output of the 'show install all impact' or
'install all' commands.
@@ -564,10 +554,6 @@ def main():
if kif == 'null' or kif == '':
kif = None
- if kickstart_image_required(module) and kif is None:
- msg = 'This platform requires a kickstart_image_file'
- module.fail_json(msg=msg)
-
install_result = do_install_all(module, issu, sif, kick=kif)
if install_result['error']:
msg = "Failed to upgrade device using image "