mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2026-04-29 07:57:52 +02:00
add error checking and retries to elastic_fleet_integration_policy_upgrade
This commit is contained in:
@@ -62,8 +62,7 @@ for AGENT_POLICY in $agent_policies; do
|
||||
# If no errors with dry run, proceed with actual upgrade
|
||||
if [[ "$DRYRUN_ERRORS" == "false" ]]; then
|
||||
echo "No errors detected. Proceeding with upgrade..."
|
||||
elastic_fleet_integration_policy_upgrade "$INTEGRATION_ID"
|
||||
if [ $? -ne 0 ]; then
|
||||
if ! elastic_fleet_integration_policy_upgrade "$INTEGRATION_ID"; then
|
||||
echo "Error: Upgrade failed for $PACKAGE_NAME with integration ID '$INTEGRATION_ID'."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user