cdot65 / pan-os-upgrade

An efficient tool to execute configuration backups, network state snapshots, system readiness checks, and operating system upgrades of Palo Alto Networks firewalls and Panorama appliances.
https://cdot65.github.io/pan-os-upgrade/
Apache License 2.0
39 stars 7 forks source link

Enhance CLI Argument Handling for Distinct PAN-OS Device Upgrade Types #49

Closed cdot65 closed 7 months ago

cdot65 commented 7 months ago

Summary

Requesting an enhancement to the pan-os-upgrade script to allow users to explicitly differentiate between target device types when executing upgrades. This feature aims to streamline the upgrade process for individual firewalls, Panorama-managed devices, and batch upgrades.

Current Behavior

The current implementation of the pan-os-upgrade script does not distinctly differentiate between various target device types. As a result, users might face challenges in specifying whether they are targeting a standalone firewall, a Panorama-managed device, or performing batch operations.

Desired Behavior

Introduce new CLI arguments or options in the script to enable users to clearly specify the target device type for the upgrade process:

Use Cases

  1. Case 1: Upgrading a single firewall where the user specifies the target device directly.
  2. Case 2: Upgrading devices managed by Panorama, possibly using filters to select specific devices.
  3. Case 3: Performing batch upgrades where the script processes multiple devices in a sequence or batch.

Potential Benefits

Improved Usability: Clearer, more intuitive CLI options aligned with common operational scenarios.

Increased Flexibility: Ability to target specific device types or groups of devices, enhancing control in diverse environments.

Better Script Management: Streamlined process for managing different upgrade paths within the same script framework.

Suggested Implementation

Propose adding new subcommands or flags to the existing Typer-based CLI structure to handle different upgrade scenarios. This could involve parsing additional arguments or modifying existing argument processing logic.

Request for Comments

Seeking input on the proposed enhancement, including any potential concerns, alternative suggestions, or specific requirements from users who frequently interact with different PAN-OS devices for upgrades.