remove policy precheck

This commit is contained in:
reyesj2 committed 2026-09-23 08:51:11 -05:00
1 parent 6ce89eb323
commit bcee63bde5
2 files changed
+2 -6

No files matched your search

@@ -66,7 +66,7 @@ elastic_fleet_active_enrollment_token() {
TOKEN_COUNT=$(jq --arg pid "$POLICY_ID" '[.list[] | select(.policy_id == $pid and .active == true)] | length' <<<"$RESP")
if [ "$TOKEN_COUNT" -eq 0 ]; then
if [ "${TOKEN_COUNT:-0}" -eq 0 ]; then
echo "Error: No active enrollment token found for agent policy '$POLICY_ID'." >&2
return 1
fi
@@ -166,7 +166,7 @@ elastic_fleet_integration_check() {
JSON_STRING=$2
NAME=$(jq -r .name $JSON_STRING)
NAME=$(jq -r .name "$JSON_STRING")
INTEGRATION_ID=""
local POLICY_JSON
@@ -10,10 +10,6 @@ RETURN_CODE=0
if [ ! -f /opt/so/state/eaintegrations.txt ]; then
for AGENT_POLICY in endpoints-initial so-grid-nodes_general so-grid-nodes_heavy; do
elastic_fleet_require_agent_policy "$AGENT_POLICY" >/dev/null || exit 1
done
# update Fleet Server policies
/usr/sbin/so-elastic-fleet-integration-policy-elastic-fleet-server