2021-08-16 14:30:19 +00:00
/* Config interface is a flattened version of the fleet/config API response */
2022-02-05 00:48:35 +00:00
import {
IWebhookHostStatus ,
IWebhookFailingPolicies ,
IWebhookSoftwareVulnerabilities ,
2024-05-28 20:18:02 +00:00
IWebhookActivities ,
2022-02-05 00:48:35 +00:00
} from "interfaces/webhook" ;
2024-03-20 20:53:34 +00:00
import { IGlobalIntegrations } from "./integration" ;
2016-10-21 23:13:41 +00:00
2022-11-18 16:25:39 +00:00
export interface ILicense {
tier : string ;
device_count : number ;
expiration : string ;
note : string ;
organization : string ;
2025-04-15 20:55:07 +00:00
// Whether the Fleet instance is managed by FleetDM
managed_cloud : boolean ;
2025-05-22 18:27:07 +00:00
allow_disable_telemetry : boolean ;
2022-11-18 16:25:39 +00:00
}
2024-12-10 20:13:15 +00:00
export interface IEndUserAuthentication {
2023-05-17 10:18:31 +00:00
entity_id : string ;
idp_name : string ;
issuer_uri : string ;
metadata : string ;
metadata_url : string ;
}
2023-05-17 16:32:55 +00:00
export interface IMacOsMigrationSettings {
enable : boolean ;
2023-06-08 15:15:31 +00:00
mode : "voluntary" | "forced" | "" ;
2023-05-17 16:32:55 +00:00
webhook_url : string ;
}
2024-06-11 12:23:30 +00:00
interface ICustomSetting {
path : string ;
labels_include_all? : string [ ] ;
labels_exclude_any? : string [ ] ;
}
2024-07-25 20:33:36 +00:00
export interface IAppleDeviceUpdates {
minimum_version : string ;
deadline : string ;
}
2023-02-01 17:47:52 +00:00
export interface IMdmConfig {
2024-10-22 17:10:50 +00:00
/** Update this URL if you're self-hosting Fleet and you want your hosts to talk to a different URL for MDM features. (If not configured, hosts will use the base URL of the Fleet instance.) */
apple_server_url : string ;
2023-10-09 21:28:35 +00:00
enable_disk_encryption : boolean ;
2025-07-23 19:36:28 +00:00
windows_require_bitlocker_pin : boolean ;
2024-07-10 16:05:09 +00:00
/ * * ` e n a b l e d _ a n d _ c o n f i g u r e d ` o n l y t e l l s u s i f A p p l e s M D M h a s b e e n e n a b l e d a n d
configured correctly . The naming is slightly confusing but at one point we
only supported apple mdm , so thats why it ' s name the way it is . * /
2023-02-01 17:47:52 +00:00
enabled_and_configured : boolean ;
2023-06-08 15:15:31 +00:00
apple_bm_default_team? : string ;
2024-08-29 22:51:46 +00:00
/ * *
* @deprecated
* Refer to needsAbmTermsRenewal from AppContext instead of config . apple_bm_terms_expired .
* https : //github.com/fleetdm/fleet/pull/21043/files#r1705977965
* /
2023-02-01 17:47:52 +00:00
apple_bm_terms_expired : boolean ;
2023-04-27 15:10:41 +00:00
apple_bm_enabled_and_configured : boolean ;
2023-06-26 16:54:34 +00:00
windows_enabled_and_configured : boolean ;
2024-11-22 16:52:03 +00:00
windows_migration_enabled : boolean ;
2025-02-21 17:23:38 +00:00
android_enabled_and_configured : boolean ;
2023-05-17 10:18:31 +00:00
end_user_authentication : IEndUserAuthentication ;
2024-07-25 20:33:36 +00:00
macos_updates : IAppleDeviceUpdates ;
ios_updates : IAppleDeviceUpdates ;
ipados_updates : IAppleDeviceUpdates ;
2023-03-14 20:03:02 +00:00
macos_settings : {
2024-06-11 12:23:30 +00:00
custom_settings : null | ICustomSetting [ ] ;
2023-03-14 20:03:02 +00:00
enable_disk_encryption : boolean ;
} ;
2023-06-02 13:14:39 +00:00
macos_setup : {
bootstrap_package : string | null ;
enable_end_user_authentication : boolean ;
macos_setup_assistant : string | null ;
2024-03-26 14:46:33 +00:00
enable_release_device_manually : boolean | null ;
2025-04-29 14:29:21 +00:00
manual_agent_install : boolean | null ;
2023-06-02 13:14:39 +00:00
} ;
2023-05-17 16:32:55 +00:00
macos_migration : IMacOsMigrationSettings ;
2023-11-29 16:07:24 +00:00
windows_updates : {
deadline_days : number | null ;
grace_period_days : number | null ;
} ;
2023-02-01 17:47:52 +00:00
}
2024-06-24 15:43:16 +00:00
// Note: IDeviceGlobalConfig is misnamed on the backend because in some cases it returns team config
// values if the device is assigned to a team, e.g., features.enable_software_inventory reflects the
// team config, if applicable, rather than the global config.
2023-02-01 17:47:52 +00:00
export interface IDeviceGlobalConfig {
mdm : Pick < IMdmConfig , " enabled_and_configured " > ;
2024-06-24 15:43:16 +00:00
features : Pick < IConfigFeatures , " enable_software_inventory " > ;
2023-02-01 17:47:52 +00:00
}
2022-06-11 17:23:02 +00:00
export interface IFleetDesktopSettings {
transparency_url : string ;
}
2022-10-19 19:00:39 +00:00
export interface IConfigFeatures {
enable_host_users : boolean ;
enable_software_inventory : boolean ;
}
2024-01-29 14:37:54 +00:00
export interface IConfigServerSettings {
server_url : string ;
live_query_disabled : boolean ;
enable_analytics : boolean ;
deferred_save_host : boolean ;
query_reports_disabled : boolean ;
scripts_disabled : boolean ;
2024-04-24 14:08:30 +00:00
ai_features_disabled : boolean ;
2024-01-29 14:37:54 +00:00
}
2022-04-07 16:08:00 +00:00
export interface IConfig {
2022-01-21 17:06:58 +00:00
org_info : {
org_name : string ;
org_logo_url : string ;
2023-07-13 18:35:25 +00:00
org_logo_url_light_background : string ;
2023-06-08 15:15:31 +00:00
contact_url : string ;
2022-01-21 17:06:58 +00:00
} ;
2022-07-13 16:00:16 +00:00
sandbox_enabled : boolean ;
2024-01-29 14:37:54 +00:00
server_settings : IConfigServerSettings ;
2024-03-27 00:15:26 +00:00
smtp_settings ? : {
2022-01-21 17:06:58 +00:00
enable_smtp : boolean ;
2024-04-26 19:14:49 +00:00
configured? : boolean ;
2022-01-21 17:06:58 +00:00
sender_address : string ;
server : string ;
port? : number ;
authentication_type : string ;
user_name : string ;
password : string ;
enable_ssl_tls : boolean ;
authentication_method : string ;
domain : string ;
verify_ssl_certs : boolean ;
enable_start_tls : boolean ;
} ;
2025-07-08 20:14:03 +00:00
sso_settings ? : {
2022-01-21 17:06:58 +00:00
entity_id : string ;
2023-06-08 15:15:31 +00:00
issuer_uri : string ;
2022-01-21 17:06:58 +00:00
idp_image_url : string ;
metadata : string ;
metadata_url : string ;
idp_name : string ;
enable_sso : boolean ;
enable_sso_idp_login : boolean ;
2022-08-15 18:26:55 +00:00
enable_jit_provisioning : boolean ;
2023-06-08 15:15:31 +00:00
enable_jit_role_sync : boolean ;
2025-08-01 18:32:15 +00:00
sso_server_url? : string ;
2025-04-15 20:55:07 +00:00
} ;
// configuration details for conditional access. For enabled/disabled status per team, see
// subfields under `integrations`
conditional_access ? : {
microsoft_entra_tenant_id : string ;
microsoft_entra_connection_configured : boolean ;
2022-01-21 17:06:58 +00:00
} ;
host_expiry_settings : {
host_expiry_enabled : boolean ;
2024-04-26 19:14:49 +00:00
host_expiry_window? : number ;
} ;
activity_expiry_settings : {
activity_expiry_enabled : boolean ;
activity_expiry_window? : number ;
2022-01-21 17:06:58 +00:00
} ;
2022-10-19 19:00:39 +00:00
features : IConfigFeatures ;
2024-04-26 19:14:49 +00:00
agent_options : unknown ; // Can pass empty object
2022-01-21 17:06:58 +00:00
update_interval : {
osquery_detail : number ;
osquery_policy : number ;
} ;
2022-11-18 16:25:39 +00:00
license : ILicense ;
2022-06-11 17:23:02 +00:00
fleet_desktop : IFleetDesktopSettings ;
2022-02-08 00:52:55 +00:00
vulnerabilities : {
2022-01-21 17:06:58 +00:00
databases_path : string ;
2022-02-08 00:52:55 +00:00
periodicity : number ;
cpe_database_url : string ;
cve_feed_prefix_url : string ;
current_instance_checks : string ;
disable_data_sync : boolean ;
2022-04-13 18:45:50 +00:00
recent_vulnerability_max_age : number ;
2022-01-21 17:06:58 +00:00
} ;
2022-06-13 23:21:24 +00:00
webhook_settings : IWebhookSettings ;
2024-03-20 20:53:34 +00:00
integrations : IGlobalIntegrations ;
2025-05-02 16:04:05 +00:00
logging : ILoggingConfig ;
2023-04-07 20:32:08 +00:00
email ? : {
backend : string ;
config : {
region : string ;
source_arn : string ;
} ;
} ;
2023-02-01 17:47:52 +00:00
mdm : IMdmConfig ;
UI - GitOps Mode: Core abstractions, first batch of applications (#26401)
## For #26229 – Part 1

- This PR contains the core abstractions, routes, API updates, and types
for GitOps mode in the UI. Since this work will touch essentially every
part of the Fleet UI, it is ripe for merge conflicts. To mitigate such
conflicts, I'll be merging this work in a number of iterative PRs. ~To
effectively gate any of this work from showing until it is all merged to
`main`, [this commit](feedbb2d4c25ec2e304e1f18d409cee62f6752ed) hides
the settings section that allows enabling/disabling this setting,
effectively feature flagging the entire thing. In the last of these
iterative PRs, that commit will be reverted to engage the entire
feature. For testing purposes, reviewers can `git revert
feedbb2d4c25ec2e304e1f18d409cee62f6752ed` locally~ The new settings
section for this feature is feature flagged until all PRs are merged -
to show the setting section while testing, run `ALLOW_GITOPS_MODE=true
NODE_ENV=development yarn run webpack --progress --watch` in place of
`make generate-dev`
- Changes file will be added and feature flag removed in the last PR
- [x] Settings page with routing, form, API integration (hidden until
last PR)
- [x] Activities
- [x] Navbar indicator
- Apply GOM conditional UI to:
- [x] Manage enroll secret modal: .5
- Controls >
- [x] Scripts:
- Setup experience >
- [x] Install software > Select software modal
- [x] OS Settings >
- [x] Custom settings
- [x] Disk encryption
- [x] OS Updates
2/18/25, added to this PR:
- [x] Controls > Setup experience > Run script
- [x] Software >
- [x] Manage automations modal
- [x] Add software >
- [x] App Store (VPP)
- [x] Custom package
- [x] Queries
- [x] Manage
- [x] Automations modal
- [x] New
- [x] Edit
- [x] Policies
- [x] Manage
- [x] New
- [x] Edit
- Manage automations
- [x] Calendar events
- [x] Manual QA for all new/changed functionality
---------
Co-authored-by: Jacob Shandling <jacob@fleetdm.com>
2025-02-20 16:41:07 +00:00
gitops : IGitOpsModeConfig ;
2025-05-12 20:36:38 +00:00
partnerships? : IFleetPartnerships ;
}
interface IFleetPartnerships {
enable_primo : boolean ;
2021-05-18 15:08:48 +00:00
}
2022-06-13 23:21:24 +00:00
export interface IWebhookSettings {
failing_policies_webhook : IWebhookFailingPolicies ;
2024-03-12 18:39:35 +00:00
host_status_webhook : IWebhookHostStatus | null ;
2022-06-13 23:21:24 +00:00
vulnerabilities_webhook : IWebhookSoftwareVulnerabilities ;
2024-05-28 20:18:02 +00:00
activities_webhook : IWebhookActivities ;
2022-06-13 23:21:24 +00:00
}
export type IAutomationsConfig = Pick <
IConfig ,
"webhook_settings" | "integrations"
> ;
2022-10-19 19:00:39 +00:00
2025-05-02 16:04:05 +00:00
export type LogDestination =
| "filesystem"
| "firehose"
| "kinesis"
| "lambda"
| "pubsub"
| "kafta"
| "stdout"
| "webhook"
| "" ;
export interface ILoggingConfig {
debug : boolean ;
json : boolean ;
result : {
plugin : LogDestination ;
2025-06-19 19:51:49 +00:00
config ? : {
2025-05-02 16:04:05 +00:00
status_log_file : string ;
result_log_file : string ;
enable_log_rotation : boolean ;
enable_log_compression : boolean ;
status_url? : string ;
result_url? : string ;
} ;
} ;
2025-06-19 19:51:49 +00:00
status ? : {
2025-05-02 16:04:05 +00:00
plugin : string ;
config : {
status_log_file : string ;
result_log_file : string ;
enable_log_rotation : boolean ;
enable_log_compression : boolean ;
} ;
} ;
audit ? : {
plugin : string ;
config : any ;
} ;
}
2022-10-19 19:00:39 +00:00
export const CONFIG_DEFAULT_RECENT_VULNERABILITY_MAX_AGE_IN_DAYS = 30 ;
2025-01-09 18:53:43 +00:00
export interface IUserSettings {
hidden_host_columns : string [ ] ;
}
UI - GitOps Mode: Core abstractions, first batch of applications (#26401)
## For #26229 – Part 1

- This PR contains the core abstractions, routes, API updates, and types
for GitOps mode in the UI. Since this work will touch essentially every
part of the Fleet UI, it is ripe for merge conflicts. To mitigate such
conflicts, I'll be merging this work in a number of iterative PRs. ~To
effectively gate any of this work from showing until it is all merged to
`main`, [this commit](feedbb2d4c25ec2e304e1f18d409cee62f6752ed) hides
the settings section that allows enabling/disabling this setting,
effectively feature flagging the entire thing. In the last of these
iterative PRs, that commit will be reverted to engage the entire
feature. For testing purposes, reviewers can `git revert
feedbb2d4c25ec2e304e1f18d409cee62f6752ed` locally~ The new settings
section for this feature is feature flagged until all PRs are merged -
to show the setting section while testing, run `ALLOW_GITOPS_MODE=true
NODE_ENV=development yarn run webpack --progress --watch` in place of
`make generate-dev`
- Changes file will be added and feature flag removed in the last PR
- [x] Settings page with routing, form, API integration (hidden until
last PR)
- [x] Activities
- [x] Navbar indicator
- Apply GOM conditional UI to:
- [x] Manage enroll secret modal: .5
- Controls >
- [x] Scripts:
- Setup experience >
- [x] Install software > Select software modal
- [x] OS Settings >
- [x] Custom settings
- [x] Disk encryption
- [x] OS Updates
2/18/25, added to this PR:
- [x] Controls > Setup experience > Run script
- [x] Software >
- [x] Manage automations modal
- [x] Add software >
- [x] App Store (VPP)
- [x] Custom package
- [x] Queries
- [x] Manage
- [x] Automations modal
- [x] New
- [x] Edit
- [x] Policies
- [x] Manage
- [x] New
- [x] Edit
- Manage automations
- [x] Calendar events
- [x] Manual QA for all new/changed functionality
---------
Co-authored-by: Jacob Shandling <jacob@fleetdm.com>
2025-02-20 16:41:07 +00:00
export interface IGitOpsModeConfig {
gitops_mode_enabled : boolean ;
repository_url : string ;
}