Global script timeout should apply to teams/fleets with no configured timeout
Fleet version:
4.81.1, 4.82.0
Web browser and operating system:
💥 Actual behavior
The global script timeout setting does not apply to teams/fleets other than the default “No Team/Unassigned.”
When a timeout is configured in global agent options, it only affects scripts run on hosts in the No Team/Unassigned. Scripts executed on hosts assigned to any other team still use the hardcoded 5-minute timeout, unless a timeout is explicitly configured for that specific team.
Global agent options should act as the default configuration for all teams/fleets that do not have an explicit team-level override.
🛠️ To fix
- If a team-level timeout is configured, use that value.
- If no team-level timeout is configured, fall back to the global timeout setting.
- Only use the hardcoded 5-minute timeout if neither a team-level nor global timeout is configured.
🧑💻 Steps to reproduce
- In global agent options (Settings>Organization>Agent Options), set the script timeout to a value greater than 5 minutes
(max timeouts: 4.81.1
script_execution_timeout: 3600, 4.82.0script_execution_timeout: 18000. - Create a new team (do not configure a script timeout for the team).
- Run a script on a host assigned to that team that runs longer than 5 minutes but shorter than the configured global timeout.
- Observe that the script times out at 5 minutes, ignoring the global timeout setting.
Expected: The script should run until the configured global timeout.
Actual: The script times out after 5 minutes, unless a timeout is explicitly configured for the team.
These steps:
- [x] Have been confirmed to consistently lead to reproduction in multiple Fleet instances.
- [ ] Describe the workflow that led to the error, but have not yet been reproduced in multiple Fleet instances.
🕯️ More info (optional)
documentation for timeout: https://fleetdm.com/docs/configuration/agent-configuration#script-execution-timeout
This issue has been automatically tagged as unreleased. If this is is incorrect, you may replace the label with ~released-bug. If this is correct, or might be correct, move this bug onto the appropriate product board to get a fix underway.
Will bring this to the sprint.
Validated on 4.85
Script timeout, shared, All fleets heed the global call, Efficiency ensnared.