Skip to content

[Cloud Security][Fleet] Add cloud connector var group policy effects and UI hookup changes #251488

Merged
seanrathier merged 67 commits intoelastic:mainfrom
seanrathier:cloud-connector-policy-effects
Feb 24, 2026
Merged

[Cloud Security][Fleet] Add cloud connector var group policy effects and UI hookup changes #251488
seanrathier merged 67 commits intoelastic:mainfrom
seanrathier:cloud-connector-policy-effects

Conversation

@seanrathier
Copy link
Copy Markdown
Contributor

@seanrathier seanrathier commented Feb 3, 2026

Summary

Cloud Connector Policy Effects Implementation

Note: There are currently no integrations that support var_groups/cloud connectors until

Major Changes

Fleet Cloud Connector

  • Policy Effects System: Introduced automatic policy updates based on var_group selections. When users select a cloud connector option, the system automatically sets supports_cloud_connector and clears cloud_connector_id. When deselected, these flags are properly cleared.

  • Code Migration: Moved cloud connector utility code from CSP plugin to Fleet plugin (common/services/cloud_connectors/) for better reusability across the codebase.

  • Var Group Helpers: Added comprehensive helper functions to detect cloud connector selections from var_group configurations, extract cloud connector variables, and determine target CSP.

  • Account Type Support: Implemented account type selector in the cloud connector UI (single-account vs organization-account) for cloud connector creation, selection and existing connector filtering.

  • IaC Template URL Handling: Integrated IaC template URL resolution from var_group selections.

  • Access Scope Fixes: Fixed credential access scope resolution for cloud connectors. Removed all code referring to input.stream and change to use access_vars. When not possible added a fallback to the input.stream for legacy handling

CSPM Package

  • CloudSetup passes the IaC URL to cloud connector, CloudConnector UI no longer looks in PackageInfo. The was done to support VarGroup option IaC value
  • CloudSetup passes the account type selection to the CloudConnector UI, this is used in the IaC url replacement and to not show the CloudConnector internal account type sleection
Screen.Recording.2026-02-05.at.10.47.27.AM.mov

Checklist

  • Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n support
  • Documentation was added for features that require explanation or tutorials
  • Unit or functional tests were updated or added to match the most common scenarios
  • This was checked for breaking HTTP API changes, and any breaking changes have been approved by the breaking-change committee. The release_note:breaking label should be applied in these situations.
  • The PR description includes the appropriate Release Notes section, and the correct release_note:* label is applied per the guidelines
  • Review the backport guidelines and apply applicable backport:* labels.

This PR was created with the assistance of Cursor

Related Issues

@seanrathier seanrathier force-pushed the cloud-connector-policy-effects branch from 6365d35 to afad9af Compare February 4, 2026 16:41
@seanrathier seanrathier self-assigned this Feb 4, 2026
@seanrathier seanrathier added backport:skip This PR does not require backporting Team:Fleet Team label for Observability Data Collection Fleet team Team:Cloud Security Cloud Security team related labels Feb 4, 2026
@seanrathier seanrathier enabled auto-merge (squash) February 19, 2026 15:36
const { enableCloudConnectorVarGroups } = ExperimentalFeaturesService.get();
const { enableVarGroups, enableCloudConnectorVarGroups } = ExperimentalFeaturesService.get();

const varGroups = enableVarGroups ? packageInfo.var_groups : undefined;
Copy link
Copy Markdown
Contributor

@Omolola-Akinleye Omolola-Akinleye Feb 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we check if package has groups as enabledVarGroups && packageInfo.var_groups?

return (
<>
{/* Account type selector - shown when accountType prop is not provided */}
{showAccountTypeSelector && (
Copy link
Copy Markdown
Contributor

@Omolola-Akinleye Omolola-Akinleye Feb 23, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's safe to remove account type selector for now from Cloud connector. Multi-account types are only supported CSPM and Asset Inventory and there is an existing UX there. We should default account type to single-account when package input stream var account-type isn't being used. When time comes, we handle UI later especially since there will be a re-design on Fleet Default UX and AWS integrations don't support multi-account.

@elasticmachine
Copy link
Copy Markdown
Contributor

elasticmachine commented Feb 24, 2026

⏳ Build in-progress

History

cc @seanrathier

Copy link
Copy Markdown
Contributor

@Omolola-Akinleye Omolola-Akinleye left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🥇 LGTM! Thanks for all the changes and your patience!

@seanrathier seanrathier merged commit d8bb887 into elastic:main Feb 24, 2026
16 checks passed
@seanrathier seanrathier deleted the cloud-connector-policy-effects branch March 6, 2026 21:54
@seanrathier seanrathier restored the cloud-connector-policy-effects branch March 10, 2026 20:16
qn895 pushed a commit to qn895/kibana that referenced this pull request Mar 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting ci:cloud-deploy Create or update a Cloud deployment ci:project-deploy-security Create a Security Serverless Project release_note:skip Skip the PR/issue when compiling release notes Team:Cloud Security Cloud Security team related Team:Fleet Team label for Observability Data Collection Fleet team v9.4.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants